Files
Krow-workspace/docs/DATACONNECT_GUIDES/DOCUMENTS/schema_dataconnect_guide.md
2026-02-16 14:52:17 -05:00

85 KiB
Raw Blame History

Data Connect Architecture Guide V.3

1. Introduction

This guide consolidates the Data Connect domain documentation into a single reference for engineers, product stakeholders, and QA. Use it to understand the entity relationships, operational flows, and available API operations across the platform.

2. Table of Contents

System Overview

Summary

Summarizes the high-level relationships between core entities in the system. Highlights the user role model and how orders progress into staffing, assignments, and invoices. Includes the communication entities that connect users, conversations, and messages.

Full Content

System Overview Flowchart

Description

This flowchart illustrates the high-level relationships between the main entities in the system. It shows the core workflows for user roles, order processing, and communication.

Flowchart

flowchart LR
    subgraph "User Roles"
        U(User) --> S(Staff)
        U --> V(Vendor)
        U --> B(Business)
    end

    subgraph "Order & Fulfillment"
        B --> O(Order)
        V --> O(Order)
        O --> SH(Shift)
        SH --> APP(Application)
        S --> APP
        APP --> AS(Assignment)
        AS --> I(Invoice)
    end

    subgraph "Communication"
        C(Conversation) --> M(Message)
        UC(UserConversation) --> U
        UC --> C
    end

    style S fill:#f9f,stroke:#333,stroke-width:2px
    style V fill:#ccf,stroke:#333,stroke-width:2px
    style B fill:#cfc,stroke:#333,stroke-width:2px

Identity Domain

Summary

Explains how users map to staff, vendors, and businesses in the identity model. Shows the role hierarchy from staff roles to roles and role categories. Focuses on the core identity relationships used across the platform.

Full Content

Identity Domain Flowchart

Description

Este diagrama de flujo detalla las relaciones de alto nivel entre las entidades de identidad clave del sistema, como usuarios, personal, proveedores, empresas y sus roles asociados.

Flowchart

flowchart LR
    U(User) --> S(Staff)
    U --> V(Vendor)
    U --> B(Business)

    S --> SR(StaffRole)
    SR --> R(Role)
    R --> RC(RoleCategory)

    style U fill:#f9f,stroke:#333,stroke-width:2px
    style S fill:#ccf,stroke:#333,stroke-width:2px
    style V fill:#cfc,stroke:#333,stroke-width:2px
    style B fill:#ffc,stroke:#333,stroke-width:2px

Operations Domain

Summary

Describes the operational lifecycle from orders through shifts and applications. Connects staffing and workforce records to assignments and invoicing outcomes. Illustrates the end-to-end flow for fulfillment and billing readiness.

Full Content

Operations Domain Flowchart

Description

This flowchart explains the lifecycle of an order, from its creation and staffing to the final invoice generation.

Flowchart

flowchart TD
    O(Order) --> S(Shift)
    S --> SR(ShiftRole)
    SR --> A(Application)
    U(User) --> A
    A --> W(WorkForce)
    W --> AS(Assignment)
    AS --> I(Invoice)

    style O fill:#f9f,stroke:#333,stroke-width:2px
    style S fill:#ccf,stroke:#333,stroke-width:2px
    style A fill:#cfc,stroke:#333,stroke-width:2px
    style AS fill:#ffc,stroke:#333,stroke-width:2px
    style I fill:#f99,stroke:#333,stroke-width:2px

Billing Domain

Summary

Centers the billing process on invoices linked to orders, businesses, and vendors. Shows how recent payments attach to invoices and reference applications for context. Provides the upstream operational context that feeds billing records.

Full Content

Billing Domain Flowchart

Description

Based on the repository's schema, the billing process centers around the Invoice entity. An Invoice is generated in the context of an Order and is explicitly linked to both a Business (the client) and a Vendor (the provider). Each invoice captures essential details from these parent entities. Financial transactions are tracked through the RecentPayment entity, which is directly tied to a specific Invoice, creating a clear record of payments made against that invoice.

Verified Relationships (evidence)

  • Invoice.vendorId -> Vendor.id (source: dataconnect/schema/invoice.gql)
  • Invoice.businessId -> Business.id (source: dataconnect/schema/invoice.gql)
  • Invoice.orderId -> Order.id (source: dataconnect/schema/invoice.gql)
  • RecentPayment.invoiceId -> Invoice.id (source: dataconnect/schema/recentPayment.gql)
  • RecentPayment.applicationId -> Application.id (source: dataconnect/schema/recentPayment.gql)

Flowchart

flowchart TD
  %% -----------------------------
  %% Billing Core
  %% -----------------------------
  B(Business) --> O(Order)
  V(Vendor) --> O
  O --> I(Invoice)
  I --> RP(RecentPayment)
  A(Application) --> RP

  %% -----------------------------
  %% Upstream Operations (Context)
  %% -----------------------------
  subgraph OPS[Upstream Operations Context]
    O --> S(Shift)
    S --> SR(ShiftRole)
    SR --> A
    ST(Staff) --> A
    A --> AS(Assignment)
    W(Workforce) --> AS
    ST --> W
  end

Teams Domain

Summary

Details how teams, members, hubs, and departments structure organizational data. Covers task management via tasks, member assignments, and task comments. Notes verified and missing relationships that affect traceability in the schema.

Full Content

Teams Domain Flowchart

Description

The Teams domain in this repository organizes users and their associated tasks. The Team is the central entity, with a User joining via the TeamMember join table, which defines their role. Teams can be structured using TeamHub (locations) and TeamHudDepartment (departments). The domain also includes task management. A Task can be assigned to a TeamMember through the MemberTask entity. Communication on tasks is handled by TaskComment, which is linked directly to the TeamMember who made the comment, providing a clear link between team structure and actionable work.

Entities in Scope

  • Team
  • TeamMember
  • User
  • TeamHub
  • TeamHudDepartment
  • Task
  • MemberTask
  • TaskComment

Verified Relationships (evidence)

  • TeamMember.teamId -> Team.id (source: dataconnect/schema/teamMember.gql)
  • TeamMember.userId -> User.id (source: dataconnect/schema/teamMember.gql)
  • TeamMember.teamHubId -> TeamHub.id (source: dataconnect/schema/teamMember.gql)
  • TeamHub.teamId -> Team.id (source: dataconnect/schema/teamHub.gql, implicit via field name)
  • TeamHudDepartment.teamHubId -> TeamHub.id (source: dataconnect/schema/teamHudDeparment.gql)
  • MemberTask.teamMemberId -> TeamMember.id (source: dataconnect/schema/memberTask.gql)
  • MemberTask.taskId -> Task.id (source: dataconnect/schema/memberTask.gql)
  • TaskComment.teamMemberId -> TeamMember.id (source: dataconnect/schema/task_comment.gql)
  • Not found: Team.ownerId is a generic String and does not have a @ref to Vendor or Business.
  • Not found: TaskComment.taskId exists but has no @ref to Task.id.

Flowchart

---
config:
  layout: elk
---
---
config:
  layout: elk
---
flowchart TB
  subgraph STRUCTURE[Team Structure]
    T(Team) --> TM(TeamMember)
    T --> TH(TeamHub)
    TH --> THD(TeamHudDepartment)
    U(User) --> TM
    TM --> TH
  end

  subgraph WORK[Work & Tasks]
    TK(Task) --> MT(MemberTask)
    TM --> MT
    TM --> TC(TaskComment)
    TK --> TC
  end

Messaging Domain

Summary

Defines conversations as the container for chat metadata and history. Links messages and user participation through user conversations. Distinguishes verified and inferred relationships between entities.

Full Content

Messaging Domain Flowchart

Description

The messaging system is designed around three core entities. The Conversation entity acts as the central container, holding metadata about a specific chat, such as its subject and type (e.g., group chat, client-vendor). The actual content of the conversation is stored in the Message entity, where each message is linked to its parent Conversation and the User who sent it. To track the state for each participant, the UserConversation entity links a User to a Conversation and stores per-user data, such as the number of unread messages and when they last read the chat.

Entities in Scope

  • Conversation
  • Message
  • UserConversation
  • User

Verified Relationships (evidence)

  • Message.senderId -> User.id (source: dataconnect/schema/message.gql)
  • UserConversation.conversationId -> Conversation.id (source: dataconnect/schema/userConversation.gql)
  • UserConversation.userId -> User.id (source: dataconnect/schema/userConversation.gql)

Inferred Relationships (if any)

  • Message.conversationId -> Conversation.id (source: dataconnect/schema/message.gql, inferred from field name)

Flowchart

flowchart TB
    subgraph "Conversation Metadata"
        C(Conversation)
    end

    subgraph "Message Content & User State"
        M(Message)
        UC(UserConversation)
        U(User)
    end

    C -- Inferred --- M
    C -- Verified --- UC

    U -- Verified --- UC
    U -- Verified --- M

Compliance Domain

Summary

Explains how staff compliance is tracked through documents and submissions. Includes required documents, tax forms, and certificates tied to staff records. Separates verified links from inferred relationships for compliance entities.

Full Content

Compliance Domain Flowchart

Description

The compliance domain manages the necessary documentation and certifications for staff members. The system defines a list of document types via the Document entity. Staff members submit their compliance files through StaffDocument, which links a specific staff member to a generic document definition. Additionally, RequiredDoc, TaxForm, and Certificate entities are used to track other specific compliance items, such as mandatory documents, tax forms (like W-4s), and professional certificates, all of which are linked back to a particular staff member.

Entities in Scope

  • Document
  • StaffDocument
  • RequiredDoc
  • TaxForm
  • Certificate
  • Staff

Verified Relationships (evidence)

  • StaffDocument.documentId -> Document.id (source: dataconnect/schema/staffDocument.gql)
  • Certificate.staffId -> Staff.id (source: dataconnect/schema/certificate.gql)

Inferred Relationships (if any)

  • StaffDocument.staffId -> Staff.id (source: dataconnect/schema/staffDocument.gql, inferred from field name)
  • RequiredDoc.staffId -> Staff.id (source: dataconnect/schema/requiredDoc.gql, inferred from field name)
  • TaxForm.staffId -> Staff.id (source: dataconnect/schema/taxForm.gql, inferred from field name)

Flowchart

flowchart TB
 subgraph subGraph0["Compliance Requirements"]
        D("Document")
  end
 subgraph subGraph1["Staff Submissions & Documents"]
        S("Staff")
        SD("StaffDocument")
        TF("TaxForm")
        C("Certificate")
  end
    D -- Verified --> SD
    S -- Inferred --> SD & TF
    S -- Verified --> C

Learning Domain

Summary

Outlines the training model with courses, categories, and levels. Shows how staff progress is captured via staff course records. Calls out relationships that are inferred versus explicitly modeled.

Full Content

Learning Domain Flowchart

Description

The learning domain provides a structured training system for staff. The core component is the Course, which represents an individual training module with a title, description, and associated Category. While the Level entity exists to define progression tiers (e.g., based on experience points), it is not directly linked to courses in the current schema. The StaffCourse entity tracks the progress of a staff member in a specific course, recording their completion status and timestamps. Certificates are not explicitly linked to course completion in the schema.

Entities in Scope

  • Course
  • Category
  • Level
  • StaffCourse
  • Staff

Verified Relationships (evidence)

  • Course.categoryId -> Category.id (source: dataconnect/schema/course.gql)

Inferred Relationships (if any)

  • StaffCourse.staffId -> Staff.id (source: dataconnect/schema/staffCourse.gql, inferred from field name)
  • StaffCourse.courseId -> Course.id (source: dataconnect/schema/staffCourse.gql, inferred from field name)

Flowchart

flowchart TB
    subgraph "Training Structure"
        C(Course)
        CAT(Category)
        L(Level)
    end

    subgraph "Staff Participation"
        S(Staff)
        SC(StaffCourse)
    end

    CAT -- Verified --> C

    S -- Verified --> SC
    C -- Verified --> SC

Sequence Diagrams

Summary

Walks through the order-to-invoice sequence based on connector operations. Lists the verified mutation steps that drive the operational flow. Visualizes participant interactions from creation through billing.

Full Content

Operations Sequence Diagrams

Flow 1: Order to Invoice

Description

Based on the repository's connector operations, the operational flow begins when a user creates an Order. From this order, one or more Shifts are generated. A Staff member can then apply to a specific Shift, creating an Application. Subsequently, an Assignment is created, linking a Workforce member to that Shift. While this represents the staffing and fulfillment part of the process, the billing cycle is handled separately. An Invoice is generated directly from the parent Order, rather than from the individual assignments, consolidating all billing at the order level.

Verified Steps (Evidence)

  • createOrder (source: dataconnect/connector/order/mutations.gql)
  • createShift (source: dataconnect/connector/shift/mutations.gql)
  • createShiftRole (source: dataconnect/connector/shiftRole/mutations.gql)
  • createApplication (source: dataconnect/connector/application/mutations.gql)
  • CreateAssignment (source: dataconnect/connector/assignment/mutations.gql)
  • createInvoice (source: dataconnect/connector/invoice/mutations.gql)

Sequence Diagram

sequenceDiagram
    participant Business as Business (Client)
    participant Vendor as Vendor (Provider)
    participant Order
    participant Shift
    participant ShiftRole
    participant Staff
    participant Application
    participant Workforce
    participant Assignment
    participant Invoice

    Business->>Order: createOrder(businessId, vendorId, ...)
    Order-->>Business: Order created (orderId)

    Vendor->>Shift: createShift(orderId, ...)
    Shift-->>Vendor: Shift created (shiftId)

    Vendor->>ShiftRole: createShiftRole(shiftId, roleId, workersNeeded, rate, ...)
    ShiftRole-->>Vendor: ShiftRole created (shiftRoleId)

    Staff->>Application: createApplication(shiftId OR shiftRoleId, staffId, ...)
    Application-->>Staff: Application submitted (applicationId)

    Vendor->>Workforce: createWorkforce(applicationId / staffId / shiftId, ...)
    Workforce-->>Vendor: Workforce created (workforceId)

    Vendor->>Assignment: createAssignment(shiftId, workforceId, staffId, ...)
    Assignment-->>Vendor: Assignment created (assignmentId)

    Vendor->>Invoice: createInvoice(orderId, businessId, vendorId, ...)
    Invoice-->>Vendor: Invoice created (invoiceId)

API Catalog

Summary

Lists every GraphQL query and mutation in the Data Connect connectors. Provides parameters and top-level return/affect fields for each operation. Organizes operations by entity folder for quick discovery and reference.

Full Content

API Catalog Data Connect

Overview

This catalog enumerates every GraphQL query and mutation defined in the Data Connect connector folders under prototypes/dataconnect/connector/. Use it to discover available operations, required parameters, and the top-level fields returned or affected by each operation.

account

Queries

Name Purpose Parameters Returns
listAccounts List accounts accounts
getAccountById Get account by id $id: UUID! account
getAccountsByOwnerId Get accounts by owner id $ownerId: UUID! accounts
filterAccounts Filter accounts $bank: String
$type: AccountType
$isPrimary: Boolean
$ownerId: UUID
accounts

Mutations

Name Purpose Parameters Affects
createAccount Create account $bank: String!
$type: AccountType!
$last4: String!
$isPrimary: Boolean
$ownerId: UUID!
$accountNumber: String
$routeNumber: String
$expiryTime: Timestamp
account_insert
updateAccount Update account $id: UUID!
$bank: String
$type: AccountType
$last4: String
$isPrimary: Boolean
$accountNumber: String
$routeNumber: String
$expiryTime: Timestamp
account_update
deleteAccount Delete account $id: UUID! account_delete

activityLog

Queries

Name Purpose Parameters Returns
listActivityLogs List activity logs $offset: Int
$limit: Int
activityLogs
getActivityLogById Get activity log by id $id: UUID! activityLog
listActivityLogsByUserId List activity logs by user id $userId: String!
$offset: Int
$limit: Int
activityLogs
listUnreadActivityLogsByUserId List unread activity logs by user id $userId: String!
$offset: Int
$limit: Int
activityLogs
filterActivityLogs Filter activity logs $userId: String
$dateFrom: Timestamp
$dateTo: Timestamp
$isRead: Boolean
$activityType: ActivityType
$iconType: ActivityIconType
$offset: Int
$limit: Int
activityLogs

Mutations

Name Purpose Parameters Affects
createActivityLog Create activity log $userId: String!
$date: Timestamp!
$hourStart: String
$hourEnd: String
$totalhours: String
$iconType: ActivityIconType
$iconColor: String
$title: String!
$description: String!
$isRead: Boolean
$activityType: ActivityType!
activityLog_insert
updateActivityLog Update activity log $id: UUID!
$userId: String
$date: Timestamp
$hourStart: String
$hourEnd: String
$totalhours: String
$iconType: ActivityIconType
$iconColor: String
$title: String
$description: String
$isRead: Boolean
$activityType: ActivityType
activityLog_update
markActivityLogAsRead Mark activity log as read $id: UUID! activityLog_update
markActivityLogsAsRead Mark activity logs as read $ids: [UUID!]! activityLog_updateMany
deleteActivityLog Delete activity log $id: UUID! activityLog_delete

application

Queries

Name Purpose Parameters Returns
listApplications List applications applications
getApplicationById Get application by id $id: UUID! application
getApplicationsByShiftId Get applications by shift id $shiftId: UUID! applications
getApplicationsByShiftIdAndStatus Get applications by shift id and status $shiftId: UUID!
$status: ApplicationStatus!
$offset: Int
$limit: Int
applications
getApplicationsByStaffId Get applications by staff id $staffId: UUID!
$offset: Int
$limit: Int
$dayStart: Timestamp
$dayEnd: Timestamp
applications
vaidateDayStaffApplication Vaidate day staff application $staffId: UUID!
$offset: Int
$limit: Int
$dayStart: Timestamp
$dayEnd: Timestamp
applications
getApplicationByStaffShiftAndRole Get application by staff shift and role $staffId: UUID!
$shiftId: UUID!
$roleId: UUID!
$offset: Int
$limit: Int
applications
listAcceptedApplicationsByShiftRoleKey List accepted applications by shift role key $shiftId: UUID!
$roleId: UUID!
$offset: Int
$limit: Int
applications
listAcceptedApplicationsByBusinessForDay List accepted applications by business for day $businessId: UUID!
$dayStart: Timestamp!
$dayEnd: Timestamp!
$offset: Int
$limit: Int
applications
listStaffsApplicationsByBusinessForDay List staffs applications by business for day $businessId: UUID!
$dayStart: Timestamp!
$dayEnd: Timestamp!
$offset: Int
$limit: Int
applications
listCompletedApplicationsByStaffId List completed applications by staff id $staffId: UUID!
$offset: Int
$limit: Int
applications

Mutations

Name Purpose Parameters Affects
createApplication Create application $shiftId: UUID!
$staffId: UUID!
$status: ApplicationStatus!
$checkInTime: Timestamp
$checkOutTime: Timestamp
$origin: ApplicationOrigin!
$roleId: UUID!
application_insert
updateApplicationStatus Update application status $id: UUID!
$shiftId: UUID
$staffId: UUID
$status: ApplicationStatus
$checkInTime: Timestamp
$checkOutTime: Timestamp
$roleId: UUID
application_update
deleteApplication Delete application $id: UUID! application_delete

assignment

Queries

Name Purpose Parameters Returns
listAssignments List assignments $offset: Int
$limit: Int
assignments
getAssignmentById Get assignment by id $id: UUID! assignment
listAssignmentsByWorkforceId List assignments by workforce id $workforceId: UUID!
$offset: Int
$limit: Int
assignments
listAssignmentsByWorkforceIds List assignments by workforce ids $workforceIds: [UUID!]!
$offset: Int
$limit: Int
assignments
listAssignmentsByShiftRole List assignments by shift role $shiftId: UUID!
$roleId: UUID!
$offset: Int
$limit: Int
assignments
represents Represents assignments
filterAssignments Filter assignments $shiftIds: [UUID!]!
$roleIds: [UUID!]!
$status: AssignmentStatus
$offset: Int
$limit: Int
assignments

Mutations

Name Purpose Parameters Affects
CreateAssignment Create assignment $workforceId: UUID!
$title: String
$description: String
$instructions: String
$status: AssignmentStatus
$tipsAvailable: Boolean
$travelTime: Boolean
$mealProvided: Boolean
$parkingAvailable: Boolean
$gasCompensation: Boolean
$managers: [Any!]
$roleId: UUID!
$shiftId: UUID!
assignment_insert
UpdateAssignment Update assignment $id: UUID!
$title: String
$description: String
$instructions: String
$status: AssignmentStatus
$tipsAvailable: Boolean
$travelTime: Boolean
$mealProvided: Boolean
$parkingAvailable: Boolean
$gasCompensation: Boolean
$managers: [Any!]
$roleId: UUID!
$shiftId: UUID!
assignment_update
DeleteAssignment Delete assignment $id: UUID! assignment_delete

attireOption

Queries

Name Purpose Parameters Returns
listAttireOptions List attire options attireOptions
getAttireOptionById Get attire option by id $id: UUID! attireOption
filterAttireOptions Filter attire options $itemId: String
$isMandatory: Boolean
$vendorId: UUID
attireOptions

Mutations

Name Purpose Parameters Affects
createAttireOption Create attire option $itemId: String!
$label: String!
$icon: String
$imageUrl: String
$isMandatory: Boolean
$vendorId: UUID
attireOption_insert
updateAttireOption Update attire option $id: UUID!
$itemId: String
$label: String
$icon: String
$imageUrl: String
$isMandatory: Boolean
$vendorId: UUID
attireOption_update
deleteAttireOption Delete attire option $id: UUID! attireOption_delete

benefitsData

Queries

Name Purpose Parameters Returns
listBenefitsData List benefits data $offset: Int
$limit: Int
benefitsDatas
getBenefitsDataByKey Get benefits data by key $staffId: UUID!
$vendorBenefitPlanId: UUID!
benefitsData
listBenefitsDataByStaffId List benefits data by staff id $staffId: UUID!
$offset: Int
$limit: Int
benefitsDatas
listBenefitsDataByVendorBenefitPlanId List benefits data by vendor benefit plan id $vendorBenefitPlanId: UUID!
$offset: Int
$limit: Int
benefitsDatas
listBenefitsDataByVendorBenefitPlanIds List benefits data by vendor benefit plan ids $vendorBenefitPlanIds: [UUID!]!
$offset: Int
$limit: Int
benefitsDatas

Mutations

Name Purpose Parameters Affects
createBenefitsData Create benefits data $vendorBenefitPlanId: UUID!
$staffId: UUID!
$current: Int!
benefitsData_insert
updateBenefitsData Update benefits data $staffId: UUID!
$vendorBenefitPlanId: UUID!
$current: Int
benefitsData_update
deleteBenefitsData Delete benefits data $staffId: UUID!
$vendorBenefitPlanId: UUID!
benefitsData_delete

business

Queries

Name Purpose Parameters Returns
listBusinesses List businesses businesses
getBusinessesByUserId Get businesses by user id $userId: String! businesses
getBusinessById Get business by id $id: UUID! business

Mutations

Name Purpose Parameters Affects
createBusiness Create business $businessName: String!
$contactName: String
$userId: String!
$companyLogoUrl: String
$phone: String
$email: String
$hubBuilding: String
$address: String
$placeId: String
$latitude: Float
$longitude: Float
$city: String
$state: String
$street: String
$country: String
$zipCode: String
$area: BusinessArea
$sector: BusinessSector
$rateGroup: BusinessRateGroup!
$status: BusinessStatus!
$notes: String
business_insert
updateBusiness Update business $id: UUID!
$businessName: String
$contactName: String
$companyLogoUrl: String
$phone: String
$email: String
$hubBuilding: String
$address: String
$placeId: String
$latitude: Float
$longitude: Float
$city: String
$state: String
$street: String
$country: String
$zipCode: String
$area: BusinessArea
$sector: BusinessSector
$rateGroup: BusinessRateGroup
$status: BusinessStatus
$notes: String
business_update
deleteBusiness Delete business $id: UUID! business_delete

category

Queries

Name Purpose Parameters Returns
listCategories List categories categories
getCategoryById Get category by id $id: UUID! category
filterCategories Filter categories $categoryId: String
$label: String
categories

Mutations

Name Purpose Parameters Affects
createCategory Create category $categoryId: String!
$label: String!
$icon: String
category_insert
updateCategory Update category $id: UUID!
$categoryId: String
$label: String
$icon: String
category_update
deleteCategory Delete category $id: UUID! category_delete

certificate

Queries

Name Purpose Parameters Returns
listCertificates List certificates certificates
getCertificateById Get certificate by id $id: UUID! certificate
listCertificatesByStaffId List certificates by staff id $staffId: UUID! certificates

Mutations

Name Purpose Parameters Affects
CreateCertificate Create certificate $name: String!
$description: String
$expiry: Timestamp
$status: CertificateStatus!
$fileUrl: String
$icon: String
$certificationType: ComplianceType
$issuer: String
$staffId: UUID!
$validationStatus: ValidationStatus
$certificateNumber: String
certificate_insert
UpdateCertificate Update certificate $id: UUID!
$name: String
$description: String
$expiry: Timestamp
$status: CertificateStatus
$fileUrl: String
$icon: String
$staffId: UUID
$certificationType: ComplianceType
$issuer: String
$validationStatus: ValidationStatus
$certificateNumber: String
certificate_update
DeleteCertificate Delete certificate $id: UUID! certificate_delete

clientFeedback

Queries

Name Purpose Parameters Returns
listClientFeedbacks List client feedbacks $offset: Int
$limit: Int
clientFeedbacks
getClientFeedbackById Get client feedback by id $id: UUID! clientFeedback
listClientFeedbacksByBusinessId List client feedbacks by business id $businessId: UUID!
$offset: Int
$limit: Int
clientFeedbacks
listClientFeedbacksByVendorId List client feedbacks by vendor id $vendorId: UUID!
$offset: Int
$limit: Int
clientFeedbacks
listClientFeedbacksByBusinessAndVendor List client feedbacks by business and vendor $businessId: UUID!
$vendorId: UUID!
$offset: Int
$limit: Int
clientFeedbacks
filterClientFeedbacks Filter client feedbacks $businessId: UUID
$vendorId: UUID
$ratingMin: Int
$ratingMax: Int
$dateFrom: Timestamp
$dateTo: Timestamp
$offset: Int
$limit: Int
clientFeedbacks
listClientFeedbackRatingsByVendorId List client feedback ratings by vendor id $vendorId: UUID!
$dateFrom: Timestamp
$dateTo: Timestamp
clientFeedbacks

Mutations

Name Purpose Parameters Affects
createClientFeedback Create client feedback $businessId: UUID!
$vendorId: UUID!
$rating: Int
$comment: String
$date: Timestamp
$createdBy: String
clientFeedback_insert
updateClientFeedback Update client feedback $id: UUID!
$businessId: UUID
$vendorId: UUID
$rating: Int
$comment: String
$date: Timestamp
$createdBy: String
clientFeedback_update
deleteClientFeedback Delete client feedback $id: UUID! clientFeedback_delete

conversation

Queries

Name Purpose Parameters Returns
listConversations List conversations $offset: Int
$limit: Int
conversations
getConversationById Get conversation by id $id: UUID! conversation
listConversationsByType List conversations by type $conversationType: ConversationType!
$offset: Int
$limit: Int
conversations
listConversationsByStatus List conversations by status $status: ConversationStatus!
$offset: Int
$limit: Int
conversations
filterConversations Filter conversations $status: ConversationStatus
$conversationType: ConversationType
$isGroup: Boolean
$lastMessageAfter: Timestamp
$lastMessageBefore: Timestamp
$offset: Int
$limit: Int
conversations

Mutations

Name Purpose Parameters Affects
createConversation Create conversation $subject: String
$status: ConversationStatus
$conversationType: ConversationType
$isGroup: Boolean
$groupName: String
$lastMessage: String
$lastMessageAt: Timestamp
conversation_insert
updateConversation Update conversation $id: UUID!
$subject: String
$status: ConversationStatus
$conversationType: ConversationType
$isGroup: Boolean
$groupName: String
$lastMessage: String
$lastMessageAt: Timestamp
conversation_update
updateConversationLastMessage Update conversation last message $id: UUID!
$lastMessage: String
$lastMessageAt: Timestamp
conversation_update
deleteConversation Delete conversation $id: UUID! conversation_delete

course

Queries

Name Purpose Parameters Returns
listCourses List courses courses
getCourseById Get course by id $id: UUID! course
filterCourses Filter courses $categoryId: UUID
$isCertification: Boolean
$levelRequired: String
$completed: Boolean
courses

Mutations

Name Purpose Parameters Affects
createCourse Create course $title: String
$description: String
$thumbnailUrl: String
$durationMinutes: Int
$xpReward: Int
$categoryId: UUID!
$levelRequired: String
$isCertification: Boolean
course_insert
updateCourse Update course $id: UUID!
$title: String
$description: String
$thumbnailUrl: String
$durationMinutes: Int
$xpReward: Int
$categoryId: UUID!
$levelRequired: String
$isCertification: Boolean
course_update
deleteCourse Delete course $id: UUID! course_delete

customRateCard

Queries

Name Purpose Parameters Returns
listCustomRateCards List custom rate cards customRateCards
getCustomRateCardById Get custom rate card by id $id: UUID! customRateCard

Mutations

Name Purpose Parameters Affects
createCustomRateCard Create custom rate card $name: String!
$baseBook: String
$discount: Float
$isDefault: Boolean
customRateCard_insert
updateCustomRateCard Update custom rate card $id: UUID!
$name: String
$baseBook: String
$discount: Float
$isDefault: Boolean
customRateCard_update
deleteCustomRateCard Delete custom rate card $id: UUID! customRateCard_delete

document

Queries

Name Purpose Parameters Returns
listDocuments List documents documents
getDocumentById Get document by id $id: UUID! document
filterDocuments Filter documents $documentType: DocumentType documents

Mutations

Name Purpose Parameters Affects
createDocument Create document $documentType: DocumentType!
$name: String!
$description: String
document_insert
updateDocument Update document $id: UUID!
$documentType: DocumentType
$name: String
$description: String
document_update
deleteDocument Delete document $id: UUID! document_delete

emergencyContact

Queries

Name Purpose Parameters Returns
listEmergencyContacts List emergency contacts emergencyContacts
getEmergencyContactById Get emergency contact by id $id: UUID! emergencyContact
getEmergencyContactsByStaffId Get emergency contacts by staff id $staffId: UUID! emergencyContacts

Mutations

Name Purpose Parameters Affects
createEmergencyContact Create emergency contact $name: String!
$phone: String!
$relationship: RelationshipType!
$staffId: UUID!
emergencyContact_insert
updateEmergencyContact Update emergency contact $id: UUID!
$name: String
$phone: String
$relationship: RelationshipType
emergencyContact_update
deleteEmergencyContact Delete emergency contact $id: UUID! emergencyContact_delete

faqData

Queries

Name Purpose Parameters Returns
listFaqDatas List faq datas faqDatas
getFaqDataById Get faq data by id $id: UUID! faqData
filterFaqDatas Filter faq datas $category: String faqDatas

Mutations

Name Purpose Parameters Affects
createFaqData Create faq data $category: String!
$questions: [Any!]
faqData_insert
updateFaqData Update faq data $id: UUID!
$category: String
$questions: [Any!]
faqData_update
deleteFaqData Delete faq data $id: UUID! faqData_delete

hub

Queries

Name Purpose Parameters Returns
listHubs List hubs hubs
getHubById Get hub by id $id: UUID! hub
getHubsByOwnerId Get hubs by owner id $ownerId: UUID! hubs
filterHubs Filter hubs $ownerId: UUID
$name: String
$nfcTagId: String
hubs

Mutations

Name Purpose Parameters Affects
createHub Create hub $name: String!
$locationName: String
$address: String
$nfcTagId: String
$ownerId: UUID!
hub_insert
updateHub Update hub $id: UUID!
$name: String
$locationName: String
$address: String
$nfcTagId: String
$ownerId: UUID
hub_update
deleteHub Delete hub $id: UUID! hub_delete

invoice

Queries

Name Purpose Parameters Returns
listInvoices List invoices $offset: Int
$limit: Int
invoices
getInvoiceById Get invoice by id $id: UUID! invoice
listInvoicesByVendorId List invoices by vendor id $vendorId: UUID!
$offset: Int
$limit: Int
invoices
listInvoicesByBusinessId List invoices by business id $businessId: UUID!
$offset: Int
$limit: Int
invoices
listInvoicesByOrderId List invoices by order id $orderId: UUID!
$offset: Int
$limit: Int
invoices
listInvoicesByStatus List invoices by status $status: InvoiceStatus!
$offset: Int
$limit: Int
invoices
filterInvoices Filter invoices $vendorId: UUID
$businessId: UUID
$orderId: UUID
$status: InvoiceStatus
$issueDateFrom: Timestamp
$issueDateTo: Timestamp
$dueDateFrom: Timestamp
$dueDateTo: Timestamp
$offset: Int
$limit: Int
invoices
listOverdueInvoices List overdue invoices $now: Timestamp!
$offset: Int
$limit: Int
invoices

Mutations

Name Purpose Parameters Affects
createInvoice Create invoice $status: InvoiceStatus!
$vendorId: UUID!
$businessId: UUID!
$orderId: UUID!
$paymentTerms: InovicePaymentTerms
$invoiceNumber: String!
$issueDate: Timestamp!
$dueDate: Timestamp!
$hub: String
$managerName: String
$vendorNumber: String
$roles: Any
$charges: Any
$otherCharges: Float
$subtotal: Float
$amount: Float!
$notes: String
$staffCount: Int
$chargesCount: Int
invoice_insert
updateInvoice Update invoice $id: UUID!
$status: InvoiceStatus
$vendorId: UUID
$businessId: UUID
$orderId: UUID
$paymentTerms: InovicePaymentTerms
$invoiceNumber: String
$issueDate: Timestamp
$dueDate: Timestamp
$hub: String
$managerName: String
$vendorNumber: String
$roles: Any
$charges: Any
$otherCharges: Float
$subtotal: Float
$amount: Float
$notes: String
$staffCount: Int
$chargesCount: Int
$disputedItems: Any
$disputeReason: String
$disputeDetails: String
invoice_update
deleteInvoice Delete invoice $id: UUID! invoice_delete

invoiceTemplate

Queries

Name Purpose Parameters Returns
listInvoiceTemplates List invoice templates $offset: Int
$limit: Int
invoiceTemplates
getInvoiceTemplateById Get invoice template by id $id: UUID! invoiceTemplate
listInvoiceTemplatesByOwnerId List invoice templates by owner id $ownerId: UUID!
$offset: Int
$limit: Int
invoiceTemplates
listInvoiceTemplatesByVendorId List invoice templates by vendor id $vendorId: UUID!
$offset: Int
$limit: Int
invoiceTemplates
listInvoiceTemplatesByBusinessId List invoice templates by business id $businessId: UUID!
$offset: Int
$limit: Int
invoiceTemplates
listInvoiceTemplatesByOrderId List invoice templates by order id $orderId: UUID!
$offset: Int
$limit: Int
invoiceTemplates
searchInvoiceTemplatesByOwnerAndName Search invoice templates by owner and name $ownerId: UUID!
$name: String!
$offset: Int
$limit: Int
invoiceTemplates

Mutations

Name Purpose Parameters Affects
createInvoiceTemplate Create invoice template $name: String!
$ownerId: UUID!
$vendorId: UUID
$businessId: UUID
$orderId: UUID
$paymentTerms: InovicePaymentTermsTemp
$invoiceNumber: String
$issueDate: Timestamp
$dueDate: Timestamp
$hub: String
$managerName: String
$vendorNumber: String
$roles: Any
$charges: Any
$otherCharges: Float
$subtotal: Float
$amount: Float
$notes: String
$staffCount: Int
$chargesCount: Int
invoiceTemplate_insert
updateInvoiceTemplate Update invoice template $id: UUID!
$name: String
$ownerId: UUID
$vendorId: UUID
$businessId: UUID
$orderId: UUID
$paymentTerms: InovicePaymentTermsTemp
$invoiceNumber: String
$issueDate: Timestamp
$dueDate: Timestamp
$hub: String
$managerName: String
$vendorNumber: String
$roles: Any
$charges: Any
$otherCharges: Float
$subtotal: Float
$amount: Float
$notes: String
$staffCount: Int
$chargesCount: Int
invoiceTemplate_update
deleteInvoiceTemplate Delete invoice template $id: UUID! invoiceTemplate_delete

level

Queries

Name Purpose Parameters Returns
listLevels List levels levels
getLevelById Get level by id $id: UUID! level
filterLevels Filter levels $name: String
$xpRequired: Int
levels

Mutations

Name Purpose Parameters Affects
createLevel Create level $name: String!
$xpRequired: Int!
$icon: String
$colors: Any
level_insert
updateLevel Update level $id: UUID!
$name: String
$xpRequired: Int
$icon: String
$colors: Any
level_update
deleteLevel Delete level $id: UUID! level_delete

memberTask

Queries

Name Purpose Parameters Returns
getMyTasks Get my tasks $teamMemberId: UUID! memberTasks
getMemberTaskByIdKey Get member task by id key $teamMemberId: UUID!
$taskId: UUID!
memberTask
getMemberTasksByTaskId Get member tasks by task id $taskId: UUID! memberTasks

Mutations

Name Purpose Parameters Affects
createMemberTask Create member task $teamMemberId: UUID!
$taskId: UUID!
memberTask_insert
deleteMemberTask Delete member task $teamMemberId: UUID!
$taskId: UUID!
memberTask_delete

message

Queries

Name Purpose Parameters Returns
listMessages List messages messages
getMessageById Get message by id $id: UUID! message
getMessagesByConversationId Get messages by conversation id $conversationId: UUID! messages

Mutations

Name Purpose Parameters Affects
createMessage Create message $conversationId: UUID!
$senderId: String!
$content: String!
$isSystem: Boolean
message_insert
updateMessage Update message $id: UUID!
$conversationId: UUID
$senderId: String
$content: String
$isSystem: Boolean
message_update
deleteMessage Delete message $id: UUID! message_delete

order

Queries

Name Purpose Parameters Returns
listOrders List orders $offset: Int
$limit: Int
orders
getOrderById Get order by id $id: UUID! order
getOrdersByBusinessId Get orders by business id $businessId: UUID!
$offset: Int
$limit: Int
orders
getOrdersByVendorId Get orders by vendor id $vendorId: UUID!
$offset: Int
$limit: Int
orders
getOrdersByStatus Get orders by status $status: OrderStatus!
$offset: Int
$limit: Int
orders
getOrdersByDateRange Get orders by date range $start: Timestamp!
$end: Timestamp!
$offset: Int
$limit: Int
orders
getRapidOrders Get rapid orders $offset: Int
$limit: Int
orders
listOrdersByBusinessAndTeamHub List orders by business and team hub $businessId: UUID!
$teamHubId: UUID!
$offset: Int
$limit: Int
orders

Mutations

Name Purpose Parameters Affects
createOrder Create order $vendorId: UUID
$businessId: UUID!
$orderType: OrderType!
$status: OrderStatus
$date: Timestamp
$startDate: Timestamp
$endDate: Timestamp
$duration: OrderDuration
$lunchBreak: Int
$total: Float
$eventName: String
$assignedStaff: Any
$shifts: Any
$requested: Int
$teamHubId: UUID!
$recurringDays: Any
$permanentStartDate: Timestamp
$permanentDays: Any
$notes: String
$detectedConflicts: Any
$poReference: String
order_insert
updateOrder Update order $id: UUID!
$vendorId: UUID
$businessId: UUID
$status: OrderStatus
$date: Timestamp
$startDate: Timestamp
$endDate: Timestamp
$total: Float
$eventName: String
$assignedStaff: Any
$shifts: Any
$requested: Int
$teamHubId: UUID!
$recurringDays: Any
$permanentDays: Any
$notes: String
$detectedConflicts: Any
$poReference: String
order_update
deleteOrder Delete order $id: UUID! order_delete

recentPayment

Queries

Name Purpose Parameters Returns
listRecentPayments List recent payments $offset: Int
$limit: Int
recentPayments
getRecentPaymentById Get recent payment by id $id: UUID! recentPayment
listRecentPaymentsByStaffId List recent payments by staff id $staffId: UUID!
$offset: Int
$limit: Int
recentPayments
listRecentPaymentsByApplicationId List recent payments by application id $applicationId: UUID!
$offset: Int
$limit: Int
recentPayments
listRecentPaymentsByInvoiceId List recent payments by invoice id $invoiceId: UUID!
$offset: Int
$limit: Int
recentPayments
listRecentPaymentsByStatus List recent payments by status $status: RecentPaymentStatus!
$offset: Int
$limit: Int
recentPayments
listRecentPaymentsByInvoiceIds List recent payments by invoice ids $invoiceIds: [UUID!]!
$offset: Int
$limit: Int
recentPayments
listRecentPaymentsByBusinessId List recent payments by business id $businessId: UUID!
$offset: Int
$limit: Int
recentPayments

Mutations

Name Purpose Parameters Affects
createRecentPayment Create recent payment $workedTime: String
$status: RecentPaymentStatus
$staffId: UUID!
$applicationId: UUID!
$invoiceId: UUID!
recentPayment_insert
updateRecentPayment Update recent payment $id: UUID!
$workedTime: String
$status: RecentPaymentStatus
$staffId: UUID
$applicationId: UUID
$invoiceId: UUID
recentPayment_update
deleteRecentPayment Delete recent payment $id: UUID! recentPayment_delete

reports

Queries

Name Purpose Parameters Returns
listShiftsForCoverage List shifts for coverage $businessId: UUID!
$startDate: Timestamp!
$endDate: Timestamp!
shifts
listApplicationsForCoverage List applications for coverage $shiftIds: [UUID!]! applications
listShiftsForDailyOpsByBusiness List shifts for daily ops by business $businessId: UUID!
$date: Timestamp!
shifts
listShiftsForDailyOpsByVendor List shifts for daily ops by vendor $vendorId: UUID!
$date: Timestamp!
shifts
listApplicationsForDailyOps List applications for daily ops $shiftIds: [UUID!]! applications
listShiftsForForecastByBusiness List shifts for forecast by business $businessId: UUID!
$startDate: Timestamp!
$endDate: Timestamp!
shifts
listShiftsForForecastByVendor List shifts for forecast by vendor $vendorId: UUID!
$startDate: Timestamp!
$endDate: Timestamp!
shifts
listShiftsForNoShowRangeByBusiness List shifts for no show range by business $businessId: UUID!
$startDate: Timestamp!
$endDate: Timestamp!
shifts
listShiftsForNoShowRangeByVendor List shifts for no show range by vendor $vendorId: UUID!
$startDate: Timestamp!
$endDate: Timestamp!
shifts
listApplicationsForNoShowRange List applications for no show range $shiftIds: [UUID!]! applications
listStaffForNoShowReport List staff for no show report $staffIds: [UUID!]! staffs
listInvoicesForSpendByBusiness List invoices for spend by business $businessId: UUID!
$startDate: Timestamp!
$endDate: Timestamp!
invoices
listInvoicesForSpendByVendor List invoices for spend by vendor $vendorId: UUID!
$startDate: Timestamp!
$endDate: Timestamp!
invoices
listInvoicesForSpendByOrder List invoices for spend by order $orderId: UUID!
$startDate: Timestamp!
$endDate: Timestamp!
invoices
listTimesheetsForSpend List timesheets for spend $startTime: Timestamp!
$endTime: Timestamp!
shiftRoles
listShiftsForPerformanceByBusiness List shifts for performance by business $businessId: UUID!
$startDate: Timestamp!
$endDate: Timestamp!
shifts
listShiftsForPerformanceByVendor List shifts for performance by vendor $vendorId: UUID!
$startDate: Timestamp!
$endDate: Timestamp!
shifts
listApplicationsForPerformance List applications for performance $shiftIds: [UUID!]! applications
listStaffForPerformance List staff for performance $staffIds: [UUID!]! staffs

Mutations

Name Purpose Parameters Affects

Notes: Used by Reports.

role

Queries

Name Purpose Parameters Returns
listRoles List roles roles
getRoleById Get role by id $id: UUID! role
listRolesByVendorId List roles by vendor id $vendorId: UUID! roles
listRolesByroleCategoryId List roles byrole category id $roleCategoryId: UUID! roles

Mutations

Name Purpose Parameters Affects
createRole Create role $name: String!
$costPerHour: Float!
$vendorId: UUID!
$roleCategoryId: UUID!
role_insert
updateRole Update role $id: UUID!
$name: String
$costPerHour: Float
$roleCategoryId: UUID!
role_update
deleteRole Delete role $id: UUID! role_delete

roleCategory

Queries

Name Purpose Parameters Returns
listRoleCategories List role categories roleCategories
getRoleCategoryById Get role category by id $id: UUID! roleCategory
getRoleCategoriesByCategory Get role categories by category $category: RoleCategoryType! roleCategories

Mutations

Name Purpose Parameters Affects
createRoleCategory Create role category $roleName: String!
$category: RoleCategoryType!
roleCategory_insert
updateRoleCategory Update role category $id: UUID!
$roleName: String
$category: RoleCategoryType
roleCategory_update
deleteRoleCategory Delete role category $id: UUID! roleCategory_delete

shift

Queries

Name Purpose Parameters Returns
listShifts List shifts $offset: Int
$limit: Int
shifts
getShiftById Get shift by id $id: UUID! shift
filterShifts Filter shifts $status: ShiftStatus
$orderId: UUID
$dateFrom: Timestamp
$dateTo: Timestamp
$offset: Int
$limit: Int
shifts
getShiftsByBusinessId Get shifts by business id $businessId: UUID!
$dateFrom: Timestamp
$dateTo: Timestamp
$offset: Int
$limit: Int
shifts
getShiftsByVendorId Get shifts by vendor id $vendorId: UUID!
$dateFrom: Timestamp
$dateTo: Timestamp
$offset: Int
$limit: Int
shifts

Mutations

Name Purpose Parameters Affects
createShift Create shift $title: String!
$orderId: UUID!
$date: Timestamp
$startTime: Timestamp
$endTime: Timestamp
$hours: Float
$cost: Float
$location: String
$locationAddress: String
$latitude: Float
$longitude: Float
$placeId: String
$city: String
$state: String
$street: String
$country: String
$description: String
$status: ShiftStatus
$workersNeeded: Int
$filled: Int
$filledAt: Timestamp
$managers: [Any!]
$durationDays: Int
$createdBy: String
shift_insert
updateShift Update shift $id: UUID!
$title: String
$orderId: UUID
$date: Timestamp
$startTime: Timestamp
$endTime: Timestamp
$hours: Float
$cost: Float
$location: String
$locationAddress: String
$latitude: Float
$longitude: Float
$placeId: String
$city: String
$state: String
$street: String
$country: String
$description: String
$status: ShiftStatus
$workersNeeded: Int
$filled: Int
$filledAt: Timestamp
$managers: [Any!]
$durationDays: Int
shift_update
deleteShift Delete shift $id: UUID! shift_delete

shiftRole

Queries

Name Purpose Parameters Returns
getShiftRoleById Get shift role by id $shiftId: UUID!
$roleId: UUID!
shiftRole
listShiftRolesByShiftId List shift roles by shift id $shiftId: UUID!
$offset: Int
$limit: Int
shiftRoles
listShiftRolesByRoleId List shift roles by role id $roleId: UUID!
$offset: Int
$limit: Int
shiftRoles
listShiftRolesByShiftIdAndTimeRange List shift roles by shift id and time range $shiftId: UUID!
$start: Timestamp!
$end: Timestamp!
$offset: Int
$limit: Int
shiftRoles
listShiftRolesByVendorId List shift roles by vendor id $vendorId: UUID!
$offset: Int
$limit: Int
shiftRoles
listShiftRolesByBusinessAndDateRange List shift roles by business and date range $businessId: UUID!
$start: Timestamp!
$end: Timestamp!
$offset: Int
$limit: Int
$status: ShiftStatus
shiftRoles
listShiftRolesByBusinessAndOrder List shift roles by business and order $businessId: UUID!
$orderId: UUID!
$offset: Int
$limit: Int
shiftRoles
listShiftRolesByBusinessDateRangeCompletedOrders List shift roles by business date range completed orders $businessId: UUID!
$start: Timestamp!
$end: Timestamp!
$offset: Int
$limit: Int
shiftRoles
listShiftRolesByBusinessAndDatesSummary List shift roles by business and dates summary $businessId: UUID!
$start: Timestamp!
$end: Timestamp!
$offset: Int
$limit: Int
shiftRoles
getCompletedShiftsByBusinessId Get completed shifts by business id $businessId: UUID!
$dateFrom: Timestamp!
$dateTo: Timestamp!
$offset: Int
$limit: Int
shifts

Mutations

Name Purpose Parameters Affects
createShiftRole Create shift role $shiftId: UUID!
$roleId: UUID!
$count: Int!
$assigned: Int
$startTime: Timestamp
$endTime: Timestamp
$hours: Float
$department: String
$uniform: String
$breakType: BreakDuration
$isBreakPaid: Boolean
$totalValue: Float
shiftRole_insert
updateShiftRole Update shift role $shiftId: UUID!
$roleId: UUID!
$count: Int
$assigned: Int
$startTime: Timestamp
$endTime: Timestamp
$hours: Float
$department: String
$uniform: String
$breakType: BreakDuration
$isBreakPaid: Boolean
$totalValue: Float
shiftRole_update
deleteShiftRole Delete shift role $shiftId: UUID!
$roleId: UUID!
shiftRole_delete

staff

Queries

Name Purpose Parameters Returns
listStaff List staff staffs
getStaffById Get staff by id $id: UUID! staff
getStaffByUserId Get staff by user id $userId: String! staffs
filterStaff Filter staff $ownerId: UUID
$fullName: String
$level: String
$email: String
staffs

Mutations

Name Purpose Parameters Affects
CreateStaff Create staff $userId: String!
$fullName: String!
$level: String
$role: String
$phone: String
$email: String
$photoUrl: String
$totalShifts: Int
$averageRating: Float
$onTimeRate: Int
$noShowCount: Int
$cancellationCount: Int
$reliabilityScore: Int
$bio: String
$skills: [String!]
$industries: [String!]
$preferredLocations: [String!]
$maxDistanceMiles: Int
$languages: Any
$itemsAttire: Any
$xp: Int
$badges: Any
$isRecommended: Boolean
$ownerId: UUID
$department: DepartmentType
$hubId: UUID
$manager: UUID
$english: EnglishProficiency
$backgroundCheckStatus: BackgroundCheckStatus
$employmentType: EmploymentType
$initial: String
$englishRequired: Boolean
$city: String
$addres: String
$placeId: String
$latitude: Float
$longitude: Float
$state: String
$street: String
$country: String
$zipCode: String
staff_insert
UpdateStaff Update staff $id: UUID!
$userId: String
$fullName: String
$level: String
$role: String
$phone: String
$email: String
$photoUrl: String
$totalShifts: Int
$averageRating: Float
$onTimeRate: Int
$noShowCount: Int
$cancellationCount: Int
$reliabilityScore: Int
$bio: String
$skills: [String!]
$industries: [String!]
$preferredLocations: [String!]
$maxDistanceMiles: Int
$languages: Any
$itemsAttire: Any
$xp: Int
$badges: Any
$isRecommended: Boolean
$ownerId: UUID
$department: DepartmentType
$hubId: UUID
$manager: UUID
$english: EnglishProficiency
$backgroundCheckStatus: BackgroundCheckStatus
$employmentType: EmploymentType
$initial: String
$englishRequired: Boolean
$city: String
$addres: String
$placeId: String
$latitude: Float
$longitude: Float
$state: String
$street: String
$country: String
$zipCode: String
staff_update
DeleteStaff Delete staff $id: UUID! staff_delete

staffAvailability

Queries

Name Purpose Parameters Returns
listStaffAvailabilities List staff availabilities $offset: Int
$limit: Int
staffAvailabilities
listStaffAvailabilitiesByStaffId List staff availabilities by staff id $staffId: UUID!
$offset: Int
$limit: Int
staffAvailabilities
getStaffAvailabilityByKey Get staff availability by key $staffId: UUID!
$day: DayOfWeek!
$slot: AvailabilitySlot!
staffAvailability
listStaffAvailabilitiesByDay List staff availabilities by day $day: DayOfWeek!
$offset: Int
$limit: Int
staffAvailabilities

Mutations

Name Purpose Parameters Affects
createStaffAvailability Create staff availability $staffId: UUID!
$day: DayOfWeek!
$slot: AvailabilitySlot!
$status: AvailabilityStatus
$notes: String
staffAvailability_insert
updateStaffAvailability Update staff availability $staffId: UUID!
$day: DayOfWeek!
$slot: AvailabilitySlot!
$status: AvailabilityStatus
$notes: String
staffAvailability_update
deleteStaffAvailability Delete staff availability $staffId: UUID!
$day: DayOfWeek!
$slot: AvailabilitySlot!
staffAvailability_delete

staffAvailabilityStats

Queries

Name Purpose Parameters Returns
listStaffAvailabilityStats List staff availability stats $offset: Int
$limit: Int
staffAvailabilityStatss
getStaffAvailabilityStatsByStaffId Get staff availability stats by staff id $staffId: UUID! staffAvailabilityStats
filterStaffAvailabilityStats Filter staff availability stats $needWorkIndexMin: Int
$needWorkIndexMax: Int
$utilizationMin: Int
$utilizationMax: Int
$acceptanceRateMin: Int
$acceptanceRateMax: Int
$lastShiftAfter: Timestamp
$lastShiftBefore: Timestamp
$offset: Int
$limit: Int
staffAvailabilityStatss

Mutations

Name Purpose Parameters Affects
createStaffAvailabilityStats Create staff availability stats $staffId: UUID!
$needWorkIndex: Int
$utilizationPercentage: Int
$predictedAvailabilityScore: Int
$scheduledHoursThisPeriod: Int
$desiredHoursThisPeriod: Int
$lastShiftDate: Timestamp
$acceptanceRate: Int
staffAvailabilityStats_insert
updateStaffAvailabilityStats Update staff availability stats $staffId: UUID!
$needWorkIndex: Int
$utilizationPercentage: Int
$predictedAvailabilityScore: Int
$scheduledHoursThisPeriod: Int
$desiredHoursThisPeriod: Int
$lastShiftDate: Timestamp
$acceptanceRate: Int
staffAvailabilityStats_update
deleteStaffAvailabilityStats Delete staff availability stats $staffId: UUID! staffAvailabilityStats_delete

staffCourse

Queries

Name Purpose Parameters Returns
getStaffCourseById Get staff course by id $id: UUID! staffCourse
listStaffCoursesByStaffId List staff courses by staff id $staffId: UUID!
$offset: Int
$limit: Int
staffCourses
listStaffCoursesByCourseId List staff courses by course id $courseId: UUID!
$offset: Int
$limit: Int
staffCourses
getStaffCourseByStaffAndCourse Get staff course by staff and course $staffId: UUID!
$courseId: UUID!
staffCourses

Mutations

Name Purpose Parameters Affects
createStaffCourse Create staff course $staffId: UUID!
$courseId: UUID!
$progressPercent: Int
$completed: Boolean
$completedAt: Timestamp
$startedAt: Timestamp
$lastAccessedAt: Timestamp
staffCourse_insert
updateStaffCourse Update staff course $id: UUID!
$progressPercent: Int
$completed: Boolean
$completedAt: Timestamp
$startedAt: Timestamp
$lastAccessedAt: Timestamp
staffCourse_update
deleteStaffCourse Delete staff course $id: UUID! staffCourse_delete

staffDocument

Queries

Name Purpose Parameters Returns
getStaffDocumentByKey Get staff document by key $staffId: UUID!
$documentId: UUID!
staffDocument
listStaffDocumentsByStaffId List staff documents by staff id $staffId: UUID!
$offset: Int
$limit: Int
staffDocuments
listStaffDocumentsByDocumentType List staff documents by document type $documentType: DocumentType!
$offset: Int
$limit: Int
staffDocuments
listStaffDocumentsByStatus List staff documents by status $status: DocumentStatus!
$offset: Int
$limit: Int
staffDocuments

Mutations

Name Purpose Parameters Affects
createStaffDocument Create staff document $staffId: UUID!
$staffName: String!
$documentId: UUID!
$status: DocumentStatus!
$documentUrl: String
$expiryDate: Timestamp
staffDocument_insert
updateStaffDocument Update staff document $staffId: UUID!
$documentId: UUID!
$status: DocumentStatus
$documentUrl: String
$expiryDate: Timestamp
staffDocument_update
deleteStaffDocument Delete staff document $staffId: UUID!
$documentId: UUID!
staffDocument_delete

staffRole

Queries

Name Purpose Parameters Returns
listStaffRoles List staff roles $offset: Int
$limit: Int
staffRoles
getStaffRoleByKey Get staff role by key $staffId: UUID!
$roleId: UUID!
staffRole
listStaffRolesByStaffId List staff roles by staff id $staffId: UUID!
$offset: Int
$limit: Int
staffRoles
listStaffRolesByRoleId List staff roles by role id $roleId: UUID!
$offset: Int
$limit: Int
staffRoles
filterStaffRoles Filter staff roles $staffId: UUID
$roleId: UUID
$offset: Int
$limit: Int
staffRoles

Mutations

Name Purpose Parameters Affects
createStaffRole Create staff role $staffId: UUID!
$roleId: UUID!
$roleType: RoleType
staffRole_insert
deleteStaffRole Delete staff role $staffId: UUID!
$roleId: UUID!
staffRole_delete

task

Queries

Name Purpose Parameters Returns
listTasks List tasks tasks
getTaskById Get task by id $id: UUID! task
getTasksByOwnerId Get tasks by owner id $ownerId: UUID! tasks
filterTasks Filter tasks $status: TaskStatus
$priority: TaskPriority
tasks

Mutations

Name Purpose Parameters Affects
createTask Create task $taskName: String!
$description: String
$priority: TaskPriority!
$status: TaskStatus!
$dueDate: Timestamp
$progress: Int
$orderIndex: Int
$commentCount: Int
$attachmentCount: Int
$files: Any
$ownerId:UUID!
task_insert
updateTask Update task $id: UUID!
$taskName: String
$description: String
$priority: TaskPriority
$status: TaskStatus
$dueDate: Timestamp
$progress: Int
$assignedMembers: Any
$orderIndex: Int
$commentCount: Int
$attachmentCount: Int
$files: Any
task_update
deleteTask Delete task $id: UUID! task_delete

task_comment

Queries

Name Purpose Parameters Returns
listTaskComments List task comments taskComments
getTaskCommentById Get task comment by id $id: UUID! taskComment
getTaskCommentsByTaskId Get task comments by task id $taskId: UUID! taskComments

Mutations

Name Purpose Parameters Affects
createTaskComment Create task comment $taskId: UUID!
$teamMemberId: UUID!
$comment: String!
$isSystem: Boolean
taskComment_insert
updateTaskComment Update task comment $id: UUID!
$comment: String
$isSystem: Boolean
taskComment_update
deleteTaskComment Delete task comment $id: UUID! taskComment_delete

taxForm

Queries

Name Purpose Parameters Returns
listTaxForms List tax forms $offset: Int
$limit: Int
taxForms
getTaxFormById Get tax form by id $id: UUID! taxForm
getTaxFormsByStaffId Get tax forms by staff id $staffId: UUID!
$offset: Int
$limit: Int
taxForms
listTaxFormsWhere List tax forms where $formType: TaxFormType
$status: TaxFormStatus
$staffId: UUID
$offset: Int
$limit: Int
taxForms

Mutations

Name Purpose Parameters Affects
createTaxForm Create tax form $formType: TaxFormType!
$firstName: String!
$lastName: String!
$mInitial: String
$oLastName: String
$dob: Timestamp
$socialSN: Int!
$email: String
$phone: String
$address: String!
$placeId: String
$latitude: Float
$longitude: Float
$city: String
$apt: String
$state: String
$street: String
$country: String
$zipCode: String
$marital: MaritalStatus
$multipleJob: Boolean
$childrens: Int
$otherDeps: Int
$totalCredits: Float
$otherInconme: Float
$deductions: Float
$extraWithholding: Float
$citizen: CitizenshipStatus
$uscis: String
$passportNumber: String
$countryIssue: String
$prepartorOrTranslator: Boolean
$signature: String
$date: Timestamp
$status: TaxFormStatus!
$staffId: UUID!
$createdBy: String
taxForm_insert
updateTaxForm Update tax form $id: UUID!
$formType: TaxFormType
$firstName: String
$lastName: String
$mInitial: String
$oLastName: String
$dob: Timestamp
$socialSN: Int
$email: String
$phone: String
$address: String
$placeId: String
$latitude: Float
$longitude: Float
$city: String
$apt: String
$state: String
$street: String
$country: String
$zipCode: String
$marital: MaritalStatus
$multipleJob: Boolean
$childrens: Int
$otherDeps: Int
$totalCredits: Float
$otherInconme: Float
$deductions: Float
$extraWithholding: Float
$citizen: CitizenshipStatus
$uscis: String
$passportNumber: String
$countryIssue: String
$prepartorOrTranslator: Boolean
$signature: String
$date: Timestamp
$status: TaxFormStatus
taxForm_update
deleteTaxForm Delete tax form $id: UUID! taxForm_delete

team

Queries

Name Purpose Parameters Returns
listTeams List teams teams
getTeamById Get team by id $id: UUID! team
getTeamsByOwnerId Get teams by owner id $ownerId: UUID! teams

Mutations

Name Purpose Parameters Affects
createTeam Create team $teamName: String!
$ownerId: UUID!
$ownerName: String!
$ownerRole: String!
$email: String
$companyLogo: String
$totalMembers: Int
$activeMembers: Int
$totalHubs: Int
$departments: Any
$favoriteStaffCount: Int
$blockedStaffCount: Int
$favoriteStaff: Any
$blockedStaff: Any
team_insert
updateTeam Update team $id: UUID!
$teamName: String
$ownerName: String
$ownerRole: String
$companyLogo: String
$totalMembers: Int
$activeMembers: Int
$totalHubs: Int
$departments: Any
$favoriteStaffCount: Int
$blockedStaffCount: Int
$favoriteStaff: Any
$blockedStaff: Any
team_update
deleteTeam Delete team $id: UUID! team_delete

teamHub

Queries

Name Purpose Parameters Returns
listTeamHubs List team hubs $offset: Int
$limit: Int
teamHubs
getTeamHubById Get team hub by id $id: UUID! teamHub
getTeamHubsByTeamId Get team hubs by team id $teamId: UUID!
$offset: Int
$limit: Int
teamHubs
listTeamHubsByOwnerId List team hubs by owner id $ownerId: UUID!
$offset: Int
$limit: Int
teamHubs

Mutations

Name Purpose Parameters Affects
createTeamHub Create team hub $teamId: UUID!
$hubName: String!
$address: String!
$placeId: String
$latitude: Float
$longitude: Float
$city: String
$state: String
$street: String
$country: String
$zipCode: String
$managerName: String
$isActive: Boolean
$departments: Any
teamHub_insert
updateTeamHub Update team hub $id: UUID!
$teamId: UUID
$hubName: String
$address: String
$placeId: String
$latitude: Float
$longitude: Float
$city: String
$state: String
$street: String
$country: String
$zipCode: String
$managerName: String
$isActive: Boolean
$departments: Any
teamHub_update
deleteTeamHub Delete team hub $id: UUID! teamHub_delete

teamHudDeparment

Queries

Name Purpose Parameters Returns
listTeamHudDepartments List team hud departments $offset: Int
$limit: Int
teamHudDepartments
getTeamHudDepartmentById Get team hud department by id $id: UUID! teamHudDepartment
listTeamHudDepartmentsByTeamHubId List team hud departments by team hub id $teamHubId: UUID!
$offset: Int
$limit: Int
teamHudDepartments

Mutations

Name Purpose Parameters Affects
createTeamHudDepartment Create team hud department $name: String!
$costCenter: String
$teamHubId: UUID!
teamHudDepartment_insert
updateTeamHudDepartment Update team hud department $id: UUID!
$name: String
$costCenter: String
$teamHubId: UUID
teamHudDepartment_update
deleteTeamHudDepartment Delete team hud department $id: UUID! teamHudDepartment_delete

teamMember

Queries

Name Purpose Parameters Returns
listTeamMembers List team members teamMembers
getTeamMemberById Get team member by id $id: UUID! teamMember
getTeamMembersByTeamId Get team members by team id $teamId: UUID! teamMembers

Mutations

Name Purpose Parameters Affects
createTeamMember Create team member $teamId: UUID!
$role: TeamMemberRole!
$title: String
$department: String
$teamHubId: UUID
$isActive: Boolean
$userId: String!
$inviteStatus: TeamMemberInviteStatus
teamMember_insert
updateTeamMember Update team member $id: UUID!
$role: TeamMemberRole
$title: String
$department: String
$teamHubId: UUID
$isActive: Boolean
$inviteStatus: TeamMemberInviteStatus
teamMember_update
updateTeamMemberInviteStatus Update team member invite status $id: UUID!
$inviteStatus: TeamMemberInviteStatus!
teamMember_update
acceptInviteByCode Accept invite by code $inviteCode: UUID! teamMember_updateMany
cancelInviteByCode Cancel invite by code $inviteCode: UUID! teamMember_updateMany
deleteTeamMember Delete team member $id: UUID! teamMember_delete

user

Queries

Name Purpose Parameters Returns
listUsers List users users
getUserById Get user by id $id: String! user
filterUsers Filter users $id: String
$email: String
$role: UserBaseRole
$userRole: String
users

Mutations

Name Purpose Parameters Affects
CreateUser Create user $id: String!
$email: String
$fullName: String
$role: UserBaseRole!
$userRole: String
$photoUrl: String
user_insert
UpdateUser Update user $id: String!
$email: String
$fullName: String
$role: UserBaseRole
$userRole: String
$photoUrl: String
user_update
DeleteUser Delete user $id: String! user_delete

userConversation

Queries

Name Purpose Parameters Returns
listUserConversations List user conversations $offset: Int
$limit: Int
userConversations
getUserConversationByKey Get user conversation by key $conversationId: UUID!
$userId: String!
userConversation
listUserConversationsByUserId List user conversations by user id $userId: String!
$offset: Int
$limit: Int
userConversations
listUnreadUserConversationsByUserId List unread user conversations by user id $userId: String!
$offset: Int
$limit: Int
userConversations
listUserConversationsByConversationId List user conversations by conversation id $conversationId: UUID!
$offset: Int
$limit: Int
userConversations
filterUserConversations Filter user conversations $userId: String
$conversationId: UUID
$unreadMin: Int
$unreadMax: Int
$lastReadAfter: Timestamp
$lastReadBefore: Timestamp
$offset: Int
$limit: Int
userConversations

Mutations

Name Purpose Parameters Affects
createUserConversation Create user conversation $conversationId: UUID!
$userId: String!
$unreadCount: Int
$lastReadAt: Timestamp
userConversation_insert
updateUserConversation Update user conversation $conversationId: UUID!
$userId: String!
$unreadCount: Int
$lastReadAt: Timestamp
userConversation_update
markConversationAsRead Mark conversation as read $conversationId: UUID!
$userId: String!
$lastReadAt: Timestamp
userConversation_update
incrementUnreadForUser Increment unread for user $conversationId: UUID!
$userId: String!
$unreadCount: Int!
userConversation_update
deleteUserConversation Delete user conversation $conversationId: UUID!
$userId: String!
userConversation_delete

vendor

Queries

Name Purpose Parameters Returns
getVendorById Get vendor by id $id: UUID! vendor
getVendorByUserId Get vendor by user id $userId: String! vendors
listVendors List vendors vendors

Mutations

Name Purpose Parameters Affects
createVendor Create vendor $userId: String!
$companyName: String!
$email: String
$phone: String
$photoUrl: String
$address: String
$placeId: String
$latitude: Float
$longitude: Float
$street: String
$country: String
$zipCode: String
$billingAddress: String
$timezone: String
$legalName: String
$doingBusinessAs: String
$region: String
$state: String
$city: String
$serviceSpecialty: String
$approvalStatus: ApprovalStatus
$isActive: Boolean
$markup: Float
$fee: Float
$csat: Float
$tier: VendorTier
vendor_insert
updateVendor Update vendor $id: UUID!
$companyName: String
$email: String
$phone: String
$photoUrl: String
$address: String
$placeId: String
$latitude: Float
$longitude: Float
$street: String
$country: String
$zipCode: String
$billingAddress: String
$timezone: String
$legalName: String
$doingBusinessAs: String
$region: String
$state: String
$city: String
$serviceSpecialty: String
$approvalStatus: ApprovalStatus
$isActive: Boolean
$markup: Float
$fee: Float
$csat: Float
$tier: VendorTier
vendor_update
deleteVendor Delete vendor $id: UUID! vendor_delete

vendorBenefitPlan

Queries

Name Purpose Parameters Returns
listVendorBenefitPlans List vendor benefit plans $offset: Int
$limit: Int
vendorBenefitPlans
getVendorBenefitPlanById Get vendor benefit plan by id $id: UUID! vendorBenefitPlan
listVendorBenefitPlansByVendorId List vendor benefit plans by vendor id $vendorId: UUID!
$offset: Int
$limit: Int
vendorBenefitPlans
listActiveVendorBenefitPlansByVendorId List active vendor benefit plans by vendor id $vendorId: UUID!
$offset: Int
$limit: Int
vendorBenefitPlans
filterVendorBenefitPlans Filter vendor benefit plans $vendorId: UUID
$title: String
$isActive: Boolean
$offset: Int
$limit: Int
vendorBenefitPlans

Mutations

Name Purpose Parameters Affects
createVendorBenefitPlan Create vendor benefit plan $vendorId: UUID!
$title: String!
$description: String
$requestLabel: String
$total: Int
$isActive: Boolean
$createdBy: String
vendorBenefitPlan_insert
updateVendorBenefitPlan Update vendor benefit plan $id: UUID!
$vendorId: UUID
$title: String
$description: String
$requestLabel: String
$total: Int
$isActive: Boolean
$createdBy: String
vendorBenefitPlan_update
deleteVendorBenefitPlan Delete vendor benefit plan $id: UUID! vendorBenefitPlan_delete

vendorRate

Queries

Name Purpose Parameters Returns
listVendorRates List vendor rates vendorRates
getVendorRateById Get vendor rate by id $id: UUID! vendorRate

Mutations

Name Purpose Parameters Affects
createVendorRate Create vendor rate $vendorId: UUID!
$roleName: String
$category: CategoryType
$clientRate: Float
$employeeWage: Float
$markupPercentage: Float
$vendorFeePercentage: Float
$isActive: Boolean
$notes: String
vendorRate_insert
updateVendorRate Update vendor rate $id: UUID!
$vendorId: UUID
$roleName: String
$category: CategoryType
$clientRate: Float
$employeeWage: Float
$markupPercentage: Float
$vendorFeePercentage: Float
$isActive: Boolean
$notes: String
vendorRate_update
deleteVendorRate Delete vendor rate $id: UUID! vendorRate_delete

workForce

Queries

Name Purpose Parameters Returns
getWorkforceById Get workforce by id $id: UUID! workforce
getWorkforceByVendorAndStaff Get workforce by vendor and staff $vendorId: UUID!
$staffId: UUID!
workforces
listWorkforceByVendorId List workforce by vendor id $vendorId: UUID!
$offset: Int
$limit: Int
workforces
listWorkforceByStaffId List workforce by staff id $staffId: UUID!
$offset: Int
$limit: Int
workforces
getWorkforceByVendorAndNumber Get workforce by vendor and number $vendorId: UUID!
$workforceNumber: String!
workforces

Mutations

Name Purpose Parameters Affects
createWorkforce Create workforce $vendorId: UUID!
$staffId: UUID!
$workforceNumber: String!
$employmentType: WorkforceEmploymentType
workforce_insert
updateWorkforce Update workforce $id: UUID!
$workforceNumber: String
$employmentType: WorkforceEmploymentType
$status: WorkforceStatus
workforce_update
deactivateWorkforce Deactivate workforce $id: UUID! workforce_update