Skip to main content

Documentation Index

Fetch the complete documentation index at: https://developers.leadwaycrm.com/llms.txt

Use this file to discover all available pages before exploring further.

Create calendar in a account.
POST https://services.leadconnectorhq.com/calendars/

Autorizacion

Authorization
string
required
Bearer token generado desde el portal Leadway. Ver Autenticacion.
Version
string
default:"2021-07-28"
required
Version de la API.

Body

isActive
boolean
Should the created calendar be active or draft
notifications
object[]
🚨 Deprecated! Please use ‘Calendar Notifications APIs’ instead.
locationId
string
default:"ocQHyuzHvysMo5N5VsXc"
required
groupId
string
default:"BqTwX8QFwXzpegMve9EQ"
Group Id
teamMembers
object[]
Team members are required for calendars of type: Round Robin, Collective, Class, Service. Personal calendar must have exactly one team member.
eventType
string
Posibles valores: ‘RoundRobin_OptimizeForAvailability’, ‘RoundRobin_OptimizeForEqualDistribution’
name
string
default:"test calendar"
required
description
string
default:"this is used for testing"
slug
string
default:"test1"
widgetSlug
string
default:"test1"
calendarType
string
Posibles valores: ‘round_robin’, ‘event’, ‘class_booking’, ‘collective’, ‘service_booking’, ‘personal’
widgetType
string
default:"classic"
Calendar widget type. Choose “default” for “neo” and “classic” for “classic” layout. Posibles valores: ‘default’, ‘classic’
eventTitle
string
eventColor
string
meetingLocation
string
🚨 Deprecated! Use locationConfigurations.account or teamMembers[].locationConfigurations.account instead.
locationConfigurations
object[]
Meeting account configuration for event calendar
slotDuration
number
This controls the duration of the meeting
slotDurationUnit
string
Unit for slot duration. Posibles valores: ‘mins’, ‘hours’
slotInterval
number
Slot interval reflects the amount of time the between booking slots that will be shown in the calendar.
slotIntervalUnit
string
Unit for slot interval. Posibles valores: ‘mins’, ‘hours’
slotBuffer
number
Slot-Buffer is additional time that can be added after an appointment, allowing for extra time to wrap up
slotBufferUnit
string
Unit for slot buffer. Posibles valores: ‘mins’, ‘hours’
preBuffer
number
Pre-Buffer is additional time that can be added before an appointment, allowing for extra time to get ready
preBufferUnit
string
Unit for pre-buffer. Posibles valores: ‘mins’, ‘hours’
appoinmentPerSlot
number
Maximum bookings per slot (per user). Maximum seats per slot in case of Class Booking Calendar.
appoinmentPerDay
number
Number of appointments that can be booked for a given day
allowBookingAfter
number
Minimum scheduling notice for events
allowBookingAfterUnit
string
default:"days"
Unit for minimum scheduling notice Posibles valores: ‘hours’, ‘days’, ‘weeks’, ‘months’
allowBookingFor
number
Minimum number of days/weeks/months for which to allow booking events
allowBookingForUnit
string
default:"days"
Unit for controlling the duration for which booking would be allowed for Posibles valores: ‘days’, ‘weeks’, ‘months’
openHours
object[]
This is only to set the standard availability. For custom availability, use the availabilities property
enableRecurring
boolean
Enable recurring appointments for the calendars. Please note that only one member should be added in the calendar to enable this
recurring
object
formId
string
stickyContact
boolean
isLivePaymentMode
boolean
autoConfirm
boolean
shouldSendAlertEmailsToAssignedMember
boolean
alertEmail
string
googleInvitationEmails
boolean
allowReschedule
boolean
allowCancellation
boolean
shouldAssignContactToTeamMember
boolean
shouldSkipAssigningContactForExisting
boolean
notes
string
pixelId
string
formSubmitType
string
Posibles valores: ‘RedirectURL’, ‘ThankYouMessage’
formSubmitRedirectURL
string
formSubmitThanksMessage
string
availabilityType
number
Determines which availability type to consider:
  • 1: Only custom availabilities will be used.
  • 0: Only open hours will be used.
  • null: Both custom availabilities and open hours will be considered. Posibles valores: 0, 1
availabilities
object[]
This is only to set the custom availability. For standard availability, use the openHours property
guestType
string
Posibles valores: ‘count_only’, ‘collect_detail’
calendarCoverImage
string
default:"https://path-to-image.com"
lookBusyConfig
object
Look Busy Configuration

Respuestas

calendar
object
required
{
  "calendar": {
    "isActive": true,
    "notifications": [
      {
        "type": "email",
        "shouldSendToContact": true,
        "shouldSendToGuest": true,
        "shouldSendToUser": true,
        "shouldSendToSelectedUsers": true,
        "selectedUsers": "user1@testemail.com,user2@testemail.com"
      }
    ],
    "locationId": "ocQHyuzHvysMo5N5VsXc",
    "groupId": "BqTwX8QFwXzpegMve9EQ",
    "teamMembers": [
      {
        "userId": "ocQHyuzHvysMo5N5VsXc",
        "priority": 0.5,
        "meetingLocationType": "custom",
        "meetingLocation": "string",
        "isPrimary": true,
        "locationConfigurations": []
      }
    ],
    "eventType": "RoundRobin_OptimizeForAvailability",
    "name": "test calendar",
    "description": "this is used for testing",
    "slug": "test1",
    "widgetSlug": "test1",
    "calendarType": "round_robin",
    "widgetType": "classic",
    "eventTitle": "{{contact.name}}",
    "eventColor": "#039be5",
    "meetingLocation": "string",
    "locationConfigurations": [
      {
        "kind": "custom",
        "location": "string",
  // truncado: 60 lineas mas
}
{}
{}

Ejemplo

curl -X POST 'https://services.leadconnectorhq.com/calendars/' \
  -H 'Authorization: Bearer YOUR_TOKEN' \
  -H 'Version: 2021-07-28' \
  -H 'Content-Type: application/json' \
  -d '{
  "isActive": true,
  "notifications": [
    {
      "type": "email",
      "shouldSendToContact": true,
      "shouldSendToGuest": true,
      "shouldSendToUser": true,
      "shouldSendToSelectedUsers": true,
      "selectedUsers": "user1@testemail.com,user2@testemail.com"
    }
  ],
  "locationId": "ocQHyuzHvysMo5N5VsXc",
  "groupId": "BqTwX8QFwXzpegMve9EQ",
  "teamMembers": [
    {
      "userId": "ocQHyuzHvysMo5N5VsXc",
      "priority": 0.5,
      "meetingLocationType": "custom",
      "meetingLocation": "string",
      "isPrimary": true,
      "locationConfigurations": [
        {}
      ]
    }
  ],
  "eventType": "RoundRobin_OptimizeForAvailability",
  "name": "test calendar",
  "description": "this is used for testing",
  "slug": "test1",
  "widgetSlug": "test1",
  "calendarType": "round_robin",
  "widgetType": "classic",
  "eventTitle": "{{contact.name}}",
  "eventColor": "#039be5",
  "meetingLocation": "string",
  "locationConfigurations": [
    {
      "kind": "custom",
      "location": "string"
    }
  ],
  "slotDuration": 30,
  "slotDurationUnit": "mins",
  "slotInterval": 30,
  "slotIntervalUnit": "mins",
  "slotBuffer": 0,
  "slotBufferUnit": "mins",
  "preBuffer": 0,
  "preBufferUnit": "mins",
  "appoinmentPerSlot": 1,
  "appoinmentPerDay": 0,
  "allowBookingAfter": 0,
  "allowBookingAfterUnit": "days",
  "allowBookingFor": 0,
  "allowBookingForUnit": "days",
  "openHours": [
    {
      "daysOfTheWeek": [
        0
      ],
      "hours": [
        {}
      ]
    }
  ],
  "enableRecurring": false,
  "recurring": {
    "freq": "DAILY",
    "count": 0,
    "bookingOption": "skip",
    "bookingOverlapDefaultStatus": "confirmed"
  },
  "formId": "string",
  "stickyContact": true,
  "isLivePaymentMode": true,
  "autoConfirm": true,
  "shouldSendAlertEmailsToAssignedMember": true,
  "alertEmail": "string",
  "googleInvitationEmails": false,
  "allowReschedule": true,
  "allowCancellation": true,
  "shouldAssignContactToTeamMember": true,
  "shouldSkipAssigningContactForExisting": true,
  "notes": "string",
  "pixelId": "string",
  "formSubmitType": "ThankYouMessage",
  "formSubmitRedirectURL": "string",
  "formSubmitThanksMessage": "string",
  "availabilityType": 0,
  "availabilities": [
    {
      "date": "2023-09-24T00:00:00.000Z",
      "hours": [
        {}
      ],
      "deleted": false
    }
  ],
  "guestType": "count_only",
  "consentLabel": "string",
  "calendarCoverImage": "https://path-to-image.com"
}'