0.0
Repository is archived
No commit activity in last 3 years
No release in over 3 years
Client for accessing YouCanBook.me APIs
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Development

Runtime

>= 1.0.1
>= 2.3.0
 Project Readme

YouCanBook.me API Client

Test codecov Gem Version license

About

These client libraries are created for YouCanBook.me API.

Installation

Add this line to your application's Gemfile:

gem 'youcanbookme'

And then execute:

$ bundle

Or install it yourself as:

$ gem install youcanbookme

Supported statuses each YouCanBook.me API

  • Account:
    • POST /v1/
    • GET /v1/{accountId}
    • PATCH /v1/{accountId}
    • DELETE /v1/{accountId}
  • Appointment Types:
    • POST /v1/{accountId}/profiles/{profileId}/appointmenttypes/items
    • PATCH /v1/{accountId}/profiles/{profileId}/appointmenttypes/items/{appointmentTypeId}
    • DELETE /v1/{accountId}/profiles/{profileId}/appointmenttypes/items/{appointmentTypeId}
  • Bookings:
    • GET /v1/{accountId}/bookings
    • GET /v1/{accountId}/profiles/{profileId}/bookings
    • POST /v1/{accountId}/profiles/{profileId}/bookings
    • GET /v1/{accountId}/profiles/{profileId}/bookings/{bookingId}
    • PATCH /v1/{accountId}/profiles/{profileId}/bookings/{bookingId}
    • DELETE /v1/{accountId}/profiles/{profileId}/bookings/{bookingId}
    • GET /v1/ics/{bookingSecret}/{bookingIdOrRef}.ics
  • Calendars:
    • GET /v1/{accountId}/remoteaccounts/{remoteAccountId}/calendars
    • POST /v1/{accountId}/remoteaccounts/{remoteAccountId}/calendars
    • GET /v1/{accountId}/remoteaccounts/{remoteAccountId}/calendars/{calendarId}
    • PUT /v1/{accountId}/remoteaccounts/{remoteAccountId}/calendars/{calendarId}
    • PATCH /v1/{accountId}/remoteaccounts/{remoteAccountId}/calendars/{calendarId}
    • DELETE /v1/{accountId}/remoteaccounts/{remoteAccountId}/calendars/{calendarId}
  • Events:
    • POST /v1/{accountId}/remoteaccounts/{remoteAccountId}/calendars/{calendarId}/events
    • GET /v1/{accountId}/remoteaccounts/{remoteAccountId}/calendars/{calendarId}/events/{eventId}
    • PATCH /v1/{accountId}/remoteaccounts/{remoteAccountId}/calendars/{calendarId}/events/{eventId}
    • DELETE /v1/{accountId}/remoteaccounts/{remoteAccountId}/calendars/{calendarId}/events/{eventId}
  • Profile
    • GET /v1/{accountId}/profiles
    • POST /v1/{accountId}/profiles
    • GET /v1/{accountId}/profiles/{profileId}
    • PATCH /v1/{accountId}/profiles/{profileId}
    • DELETE /v1/{accountId}/profiles/{profileId}
    • GET /v1/{accountId}/profiles/{profileId}/suggestedactions
    • GET /v1/subdomains/{subdomain}
    • GET /v1/suggestedsubdomains
  • Query
    • POST /v1/{accountId}/queries
  • Remote Account
    • GET /v1/{accountId}/remoteaccounts
    • POST /v1/{accountId}/remoteaccounts
    • GET /v1/{accountId}/remoteaccounts/{remoteAccountId}
    • PATCH /v1/{accountId}/remoteaccounts/{remoteAccountId}
    • DELETE /v1/{accountId}/remoteaccounts/{remoteAccountId}
  • Team Members:
    • POST /v1/{accountId}/profiles/{profileId}/teammembers/items
    • PATCH /v1/{accountId}/profiles/{profileId}/teammembers/items/{teamMemberId}
    • DELETE /v1/{accountId}/profiles/{profileId}/teammembers/items/{teamMemberId}

Usage

The APIs client needs account email and password(or token). This client setup step is below.

# set token by YouCanBookMe.configure methods.
YouCanBookMe.configure do |config|
  config.username          = 'foobar@example.com'
  config.password_or_token = '<PASSWORD_OR_TOKEN>'
end
client = YouCanBookMe::Client.new

# set token by YouCanBookMe::Client initializer.
username          = 'foobar@example.com'
password_or_token = '<PASSWORD_OR_TOKEN>'
client = YouCanBookMe::Client.new username, password_or_token

This client basic usage is below.

TODO

Contributing

Bug reports and pull requests are welcome on GitHub. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the Contributor Covenant code of conduct.

License

The gem is available as open source under the terms of the MIT License.

Code of Conduct

Everyone interacting in the youcanbookme Api Client project’s codebases, issue trackers, chat rooms and mailing lists is expected to follow the code of conduct.