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 unit types
  • Get unit type
  • Edit unit type
  • Delete unit type
  1. Spaces & Inventory

Unit Types

See Structure & Terms for information on what a unit type is.

Types

type UnitType {
    accessDescription: string
    additionalInformation: string
    code: string
    currencyCode: string
    locationDescription: string
    manualPricingEnabled: boolean
    marketingTitle: string
    marketingDescription: string
    maxOccupants: number
    numberOfBathrooms: number
    numberOfBedrooms: number
    sizeInSqm: number
    spaceDescription: string

    transitDescription: string
    vat: number
    editable: boolean
    editableAddress: boolean
    residential: boolean
    translations: Translation[] # See the building type
    address: Address # See the building type
}

Search / List unit types

input UnitTypeSearchQueryInput {
   workspaceIds: ID[]
   buildingIds: ID[]
}

query {
    spaces {
       unitTypes {
          search(
             q: UnitTypeSearchQueryInput
          ) {
             edges {
                node {
                   # Unit Type
                }
             }
          }   
       }
    }
}

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

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

Get unit type

query {
    spaces {
       unitType(unitTypeId: ID) {
          # Unit Type
       }
    }
}

In addition to the unit type data. You can also use the units subquery for accessing the list of units belonging to the unit type. See Units for more information.

Edit unit type

mutation {
    spaces {
       unitTypes {
          update(
             unitTypeId: ID
             data: UnitType
          ) {
             # Unit Type
          }   
       }
    }
}

Delete unit type

mutation {
    spaces {
       unitTypes {
          delete(
             unitTypeId: ID
          ) 
       }
    }
}
PreviousBuildingsNextUnits

Last updated 1 year ago