Skip to content

w0bbes/youcanbookme-api-wrapper

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 

Repository files navigation

Youcanbook.me API wrapper

A very small wrapper for the Youcanbook.me api.

You set the credentials, it will grab the first profile on your dashboard and you can submit bookings to it.

Usage

import YouCanBookMeApi from './youcanbookme-api-wrapper'

Init:

const apiWrapper = new YouCanBookMeApi()

Note: I personally supply an isomorphic-fetch instance to the wrapper by using:

apiWrapper.fetch = fetch

Set your credentials:

apiWrapper.setCredentials(email, password)

Note: here password is the password you set explicitly on your dashboard.

Book:

apiWrapper.book(date, firstName, lastName, email)

Date is in the following format:

'Y-m-d H:i'

Notes

This is a WIP Todo:

  • Support more profiles.
  • Show availability (there is not api for this right now, support says it's not publicly available because of security reasons). We could, however, scrape the html.
  • Get the fields we need to submit a booking to reflect the ones from the dashboard. Right now we only support first name, last name and email

About

A tiny wrapper for the Youcanbook.me api

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published