Lavanda Developer Docs
  • Welcome
  • Quickstart
    • Getting Started
    • Versioning
    • API Explorer
  • Concepts
    • Structure & Terms
    • Auth
    • Webhooks
    • API Paradigms
      • Connections
      • Pagination (Cursors)
      • Client Name Header
  • CRM
    • Leads
    • Contacts
    • Companies
    • Institutions
    • Offers
    • Subjects
  • Bookings
    • Bookings
  • Spaces & Inventory
    • Buildings
    • Unit Types
    • Units
  • Availability
    • Availability
  • Pricing
    • Pricing
    • Product
  • Ecommerce
    • Flow
    • Search
    • Checkout
  • Guest Messaging
    • General
  • Finance & Accounting
    • Invoices
    • Payments
  • Tickets
    • Tickets
    • Tasks
    • Charges
  • Users
    • Queries
      • whoami
    • Mutations
  • Legacy
    • README
    • Auth
    • Create Lead
    • Legacy Azure API
Powered by GitBook
On this page
  • Types
  • Search / List offers
  • Get offer
  • Edit offer
  • Delete offer
  1. CRM

Offers

Types

type CrmOffer {
    id: ID
    contractRequired: boolean
    downPaymount {
        amountCents: number
        currency: string
    }
    checkIn: Date
    checkOut: Date
    expiresAfter: Date
    contractTemplateId: string # uuidv4
    holdCalendar: boolean
    requiresApplication: boolean
    status: string
    uniqueReference: string
    
    createdBy: PmsUser # See auth and identity
    building: Building # See building page
    
    accommodation: CrmOfferAccommodation[]
    
    lead: CrmLead
}

type CrmOfferAccommodation {
    id: ID
    unitType: UnitType # See unit types page
}

Search / List offers

input CrmOffersSearchQueryInput {
   workspaceIds: ID[]
   leadIds: ID[]
}

query {
    crm {
       offers {
          search(
             q: CrmOffersSearchQueryInput
          ) {
             edges {
                node {
                   # CrmOffer
                }
             }
          }   
       }
    }
}

* For brevity cursor types have been excluded - See Pagination (Cursors)

** For brevity most connection keys have been excluded - See Connections

Get offer

query {
    crm {
       offer(offerId: ID) {
          # CrmOffer
       }
    }
}

Edit offer

mutation {
    crm {
       offers {
          update(
             offerId: ID
             data: CrmOffer
          ) {
             # CrmOffer
          }   
       }
    }
}

Delete offer

mutation {
    crm {
       offers {
          delete(
             offerId: ID
          ) 
       }
    }
}
PreviousInstitutionsNextSubjects

Last updated 1 year ago