We have a Sandbox environment to play with!
Just use sandbox.gonebusy.com instead of where you see beta.gonebusy.com referenced, including where to create an account to retrieve your API Key.
The Sandbox environment is completely separate from the Live site - that includes meaning your Sandbox API Key will not work in the Live environment.
This client library is a Ruby gem which can be compiled and used in your Ruby and Ruby on Rails project. This library requires a few gems from the RubyGems repository.
Open the command line interface or the terminal and navigate to the folder containing the source code.
Run gem build gonebusy.gemspec to build the gem.
Once built, the gem can be installed on the current work environment using gem install gonebusy-0.1.3.gem
If testing with Sandbox, Signup/Logon at https://sandbox.gonebusy.com/login .
If using Production site, Signup/Logon at https://beta.gonebusy.com/login .
Once logged in, navigate to the API Key page and request an API key.
Initialization/Authentication
In order to setup authentication and initialization of the API client, you need the following information.
Parameter
Description
authorization
Set Authorization to "Token your API key "
API client can be initialized as following.
# Configuration parameters and credentials
authorization = "Token <your API key>" ; # Set Authorization to "Token <your API key>"
client = Gonebusy ::GonebusyClient . new ( authorization )
You can test the generated SDK and the server with automatically generated test
cases as follows:
From terminal/cmd navigate to the root directory of the SDK.
Invoke: bundle exec rake
BookingsController
The singleton instance of the BookingsController class can be accessed from the API Client.
bookings = client . bookings
create_booking
Create a Booking with params
def create_booking ( options = Hash . new ) ; end
Parameter
Tags
Description
authorization
Required
A valid API key, in the format 'Token API_KEY'
create_booking_body
Required
the content of the request
collect = Hash . new
authorization = 'Authorization'
collect [ 'authorization' ] = authorization
create_booking_body = CreateBookingBody . new
collect [ 'create_booking_body' ] = create_booking_body
result = bookings . create_booking ( collect )
Error Code
Error Description
400
Bad Request
401
Unauthorized/Missing Token
403
Forbidden
422
Unprocessable Entity
500
Unexpected error
get_bookings
Return list of Bookings.
def get_bookings ( options = Hash . new ) ; end
Parameter
Tags
Description
authorization
Required
A valid API key, in the format 'Token API_KEY'
page
Optional DefaultValue
Page offset to fetch.
per_page
Optional DefaultValue
Number of results to return per page.
states
Optional
Comma-separated list of Booking states to retrieve only Bookings in those states. Leave blank to retrieve all Bookings.
user_id
Optional
Retrieve Bookings for Resources/Services owned by this User Id. You must be authorized to manage this User Id.
booker_id
Optional
Retrieve Bookings make by Booker Id.
collect = Hash . new
authorization = 'Authorization'
collect [ 'authorization' ] = authorization
page = 1
collect [ 'page' ] = page
per_page = 10
collect [ 'per_page' ] = per_page
states = 'states'
collect [ 'states' ] = states
user_id = 86
collect [ 'user_id' ] = user_id
result = bookings . get_bookings ( collect )
Error Code
Error Description
401
Unauthorized/Missing Token
403
Forbidden
404
Not Found
500
Unexpected error
cancel_booking_by_id
Cancel a Booking by id
def cancel_booking_by_id ( authorization ,
id ,
cancel_recurring = nil ,
date = nil ,
end_date = nil ) ; end
Parameter
Tags
Description
authorization
Required
A valid API key, in the format 'Token API_KEY'
id
Required
TODO: Add a parameter description
cancel_recurring
Optional
When a recurring booking, one of: ['instance', 'all', 'infinite']
date
Optional
If a recurring booking, the date of an instance to cancel. Several formats are supported: '2014-10-31', 'October 31, 2014'
end_date
Optional
If recurring, cancel up to :end_date or leave blank for infinite booking. Several formats are supported: '2014-10-31', 'October 31, 2014'.
authorization = 'Authorization'
id = 'id'
cancel_recurring = 'cancel_recurring'
date = DateTime . now
end_date = DateTime . now
result = bookings . cancel_booking_by_id ( authorization , id , cancel_recurring , date , end_date )
Error Code
Error Description
400
Bad Request
401
Unauthorized/Missing Token
403
Forbidden
404
Not Found
500
Unexpected error
update_booking_by_id
Update a Booking by id
def update_booking_by_id ( authorization ,
id ,
update_booking_by_id_body = nil ) ; end
Parameter
Tags
Description
authorization
Required
A valid API key, in the format 'Token API_KEY'
id
Required
TODO: Add a parameter description
update_booking_by_id_body
Optional
the content of the request
authorization = 'Authorization'
id = 'id'
update_booking_by_id_body = UpdateBookingByIdBody . new
result = bookings . update_booking_by_id ( authorization , id , update_booking_by_id_body )
Error Code
Error Description
400
Bad Request
401
Unauthorized/Missing Token
403
Forbidden
404
Not Found
422
Unprocessable Entity
500
Unexpected error
get_booking_by_id
Return a Booking by id.
def get_booking_by_id ( options = Hash . new ) ; end
Parameter
Tags
Description
authorization
Required
A valid API key, in the format 'Token API_KEY'
id
Required
TODO: Add a parameter description
collect = Hash . new
authorization = 'Authorization'
collect [ 'authorization' ] = authorization
id = 'id'
collect [ 'id' ] = id
result = bookings . get_booking_by_id ( collect )
Error Code
Error Description
400
Bad Request
401
Unauthorized/Missing Token
403
Forbidden
404
Not Found
500
Unexpected error
Back to List of Controllers
UsersController
The singleton instance of the UsersController class can be accessed from the API Client.
update_user_by_id
Update a User by id, with params.
def update_user_by_id ( options = Hash . new ) ; end
Parameter
Tags
Description
authorization
Required
A valid API key, in the format 'Token API_KEY'
id
Required
TODO: Add a parameter description
update_user_by_id_body
Required
the content of the request
collect = Hash . new
authorization = 'Authorization'
collect [ 'authorization' ] = authorization
id = 'id'
collect [ 'id' ] = id
update_user_by_id_body = UpdateUserByIdBody . new
collect [ 'update_user_by_id_body' ] = update_user_by_id_body
result = users . update_user_by_id ( collect )
Error Code
Error Description
400
Bad Request
401
Unauthorized/Missing Token
403
Forbidden
404
Not Found
422
Unprocessable Entity
500
Unexpected error
get_user_by_id
Return a User by id.
def get_user_by_id ( options = Hash . new ) ; end
Parameter
Tags
Description
authorization
Required
A valid API key, in the format 'Token API_KEY'
id
Required
TODO: Add a parameter description
collect = Hash . new
authorization = 'Authorization'
collect [ 'authorization' ] = authorization
id = 'id'
collect [ 'id' ] = id
result = users . get_user_by_id ( collect )
Error Code
Error Description
400
Bad Request
401
Unauthorized/Missing Token
403
Forbidden
404
Not Found
500
Unexpected error
get_users_pros
Return list of active Pro Users.
def get_users_pros ( authorization ) ; end
Parameter
Tags
Description
authorization
Required
A valid API key, in the format 'Token API_KEY'
authorization = 'Authorization'
result = users . get_users_pros ( authorization )
Error Code
Error Description
400
Bad Request
401
Unauthorized/Missing Token
403
Forbidden
500
Unexpected error
create_user
Create a User
def create_user ( options = Hash . new ) ; end
Parameter
Tags
Description
authorization
Required
A valid API key, in the format 'Token API_KEY'
create_user_body
Required
the content of the request
collect = Hash . new
authorization = 'Authorization'
collect [ 'authorization' ] = authorization
create_user_body = CreateUserBody . new
collect [ 'create_user_body' ] = create_user_body
result = users . create_user ( collect )
Error Code
Error Description
400
Bad Request
401
Unauthorized/Missing Token
403
Forbidden
422
Unprocessable Entity
500
Unexpected error
get_users
Return all Users that your account has access to. Includes your own User as well as any Users for which you are the Account Manager.
def get_users ( options = Hash . new ) ; end
Parameter
Tags
Description
authorization
Required
A valid API key, in the format 'Token API_KEY'
page
Optional DefaultValue
Page offset to fetch.
per_page
Optional DefaultValue
Number of results to return per page.
collect = Hash . new
authorization = 'Authorization'
collect [ 'authorization' ] = authorization
page = 1
collect [ 'page' ] = page
per_page = 10
collect [ 'per_page' ] = per_page
result = users . get_users ( collect )
Error Code
Error Description
400
Bad Request
401
Unauthorized/Missing Token
403
Forbidden
500
Unexpected error
Back to List of Controllers
ServicesController
The singleton instance of the ServicesController class can be accessed from the API Client.
services = client . services
delete_service_by_id
Delete a Service by id
def delete_service_by_id ( options = Hash . new ) ; end
Parameter
Tags
Description
authorization
Required
A valid API key, in the format 'Token API_KEY'
id
Required
TODO: Add a parameter description
collect = Hash . new
authorization = 'Authorization'
collect [ 'authorization' ] = authorization
id = 'id'
collect [ 'id' ] = id
result = services . delete_service_by_id ( collect )
Error Code
Error Description
400
Bad Request
401
Unauthorized/Missing Token
403
Forbidden
404
Not Found
500
Unexpected error
update_service_by_id
Update a Service with params.
def update_service_by_id ( options = Hash . new ) ; end
Parameter
Tags
Description
authorization
Required
A valid API key, in the format 'Token API_KEY'
id
Required
TODO: Add a parameter description
update_service_by_id_body
Required
the content of the request
collect = Hash . new
authorization = 'Authorization'
collect [ 'authorization' ] = authorization
id = 'id'
collect [ 'id' ] = id
update_service_by_id_body = UpdateServiceByIdBody . new
collect [ 'update_service_by_id_body' ] = update_service_by_id_body
result = services . update_service_by_id ( collect )
Error Code
Error Description
400
Bad Request
401
Unauthorized/Missing Token
403
Forbidden
404
Not Found
422
Unprocessable Entity
500
Unexpected error
get_service_by_id
Return a Service by id.
def get_service_by_id ( options = Hash . new ) ; end
Parameter
Tags
Description
authorization
Required
A valid API key, in the format 'Token API_KEY'
id
Required
TODO: Add a parameter description
collect = Hash . new
authorization = 'Authorization'
collect [ 'authorization' ] = authorization
id = 'id'
collect [ 'id' ] = id
result = services . get_service_by_id ( collect )
Error Code
Error Description
400
Bad Request
401
Unauthorized/Missing Token
403
Forbidden
404
Not Found
500
Unexpected error
create_service
Create a Service with params.
def create_service ( options = Hash . new ) ; end
Parameter
Tags
Description
authorization
Required
A valid API key, in the format 'Token API_KEY'
create_service_body
Required
the content of the request
collect = Hash . new
authorization = 'Authorization'
collect [ 'authorization' ] = authorization
create_service_body = CreateServiceBody . new
collect [ 'create_service_body' ] = create_service_body
result = services . create_service ( collect )
Error Code
Error Description
400
Bad Request
401
Unauthorized/Missing Token
403
Forbidden
404
Not Found
422
Unprocessable Entity
500
Unexpected error
get_services
Return list of Services.
def get_services ( options = Hash . new ) ; end
Parameter
Tags
Description
authorization
Required
A valid API key, in the format 'Token API_KEY'
page
Optional DefaultValue
Page offset to fetch.
per_page
Optional DefaultValue
Number of results to return per page.
user_id
Optional
Retrieve Services provided by the User specified by Id. You must be authorized to manage this User Id.
collect = Hash . new
authorization = 'Authorization'
collect [ 'authorization' ] = authorization
page = 1
collect [ 'page' ] = page
per_page = 10
collect [ 'per_page' ] = per_page
user_id = 45
collect [ 'user_id' ] = user_id
result = services . get_services ( collect )
Error Code
Error Description
401
Unauthorized/Missing Token
403
Forbidden
404
Not Found
500
Unexpected error
get_service_available_slots_by_id
Return available times for a Service.
def get_service_available_slots_by_id ( options = Hash . new ) ; end
Parameter
Tags
Description
authorization
Required
A valid API key, in the format 'Token API_KEY'
id
Required
TODO: Add a parameter description
date
Optional
Date to check for availability. Either this field or a date range employing start_date and end_date must be supplied. If date is provided, start_date/end_date are ignored. Several formats are supported: '2014-10-31', 'October 31, 2014'.
end_date
Optional
End Date of a range to check for availability. If supplied, date must not be supplied and start_date must be supplied. Several formats are supported: '2014-10-31', 'October 31, 2014'.
start_date
Optional
Start Date of a range to check for availability. If supplied, date must not be supplied and end_date must be supplied. Several formats are supported: '2014-10-31', 'October 31, 2014'.
collect = Hash . new
authorization = 'Authorization'
collect [ 'authorization' ] = authorization
id = 'id'
collect [ 'id' ] = id
date = DateTime . now
collect [ 'date' ] = date
end_date = DateTime . now
collect [ 'end_date' ] = end_date
start_date = DateTime . now
collect [ 'start_date' ] = start_date
result = services . get_service_available_slots_by_id ( collect )
Error Code
Error Description
400
Bad Request
401
Unauthorized/Missing Token
403
Forbidden
404
Not Found
500
Unexpected error
Back to List of Controllers
SearchController
The singleton instance of the SearchController class can be accessed from the API Client.
search_query
Search for Providers and Provided Services.
def search_query ( options = Hash . new ) ; end
Parameter
Tags
Description
authorization
Required
A valid API key, in the format 'Token API_KEY'
query
Required
TODO: Add a parameter description
collect = Hash . new
authorization = 'Authorization'
collect [ 'authorization' ] = authorization
query = 'query'
collect [ 'query' ] = query
result = search . search_query ( collect )
Error Code
Error Description
400
Bad Request
401
Unauthorized/Missing Token
500
Unexpected error
Back to List of Controllers
SchedulesController
The singleton instance of the SchedulesController class can be accessed from the API Client.
schedules = client . schedules
delete_schedule_time_window_by_id
Delete a TimeWindow from a Schedule
def delete_schedule_time_window_by_id ( options = Hash . new ) ; end
Parameter
Tags
Description
authorization
Required
A valid API key, in the format 'Token API_KEY'
id
Required
TODO: Add a parameter description
time_window_id
Required
TODO: Add a parameter description
collect = Hash . new
authorization = 'Authorization'
collect [ 'authorization' ] = authorization
id = 'id'
collect [ 'id' ] = id
time_window_id = 'time_window_id'
collect [ 'time_window_id' ] = time_window_id
result = schedules . delete_schedule_time_window_by_id ( collect )
Error Code
Error Description
400
Bad Request
401
Unauthorized/Missing Token
403
Forbidden
404
Not Found
500
Unexpected error
create_schedule_time_window
Add a TimeWindow to a Schedule.
def create_schedule_time_window ( options = Hash . new ) ; end
Parameter
Tags
Description
authorization
Required
A valid API key, in the format 'Token API_KEY'
create_schedule_time_window_body
Required
the content of the request
id
Required
TODO: Add a parameter description
collect = Hash . new
authorization = 'Authorization'
collect [ 'authorization' ] = authorization
create_schedule_time_window_body = CreateScheduleTimeWindowBody . new
collect [ 'create_schedule_time_window_body' ] = create_schedule_time_window_body
id = 'id'
collect [ 'id' ] = id
result = schedules . create_schedule_time_window ( collect )
Error Code
Error Description
400
Bad Request
401
Unauthorized/Missing Token
403
Forbidden
404
Not Found
422
Unprocessable Entity
500
Unexpected error
delete_schedule_by_id
Delete a Schedule
def delete_schedule_by_id ( options = Hash . new ) ; end
Parameter
Tags
Description
authorization
Required
A valid API key, in the format 'Token API_KEY'
id
Required
TODO: Add a parameter description
collect = Hash . new
authorization = 'Authorization'
collect [ 'authorization' ] = authorization
id = 'id'
collect [ 'id' ] = id
result = schedules . delete_schedule_by_id ( collect )
Error Code
Error Description
400
Bad Request
401
Unauthorized/Missing Token
403
Forbidden
404
Not Found
500
Unexpected error
get_schedule_by_id
Return a Schedule by id.
def get_schedule_by_id ( options = Hash . new ) ; end
Parameter
Tags
Description
authorization
Required
A valid API key, in the format 'Token API_KEY'
id
Required
TODO: Add a parameter description
collect = Hash . new
authorization = 'Authorization'
collect [ 'authorization' ] = authorization
id = 'id'
collect [ 'id' ] = id
result = schedules . get_schedule_by_id ( collect )
Error Code
Error Description
400
Bad Request
401
Unauthorized/Missing Token
403
Forbidden
404
Not Found
410
Gone
500
Unexpected error
create_schedule
Create a Schedule with params.
def create_schedule ( options = Hash . new ) ; end
Parameter
Tags
Description
authorization
Required
A valid API key, in the format 'Token API_KEY'
create_schedule_body
Required
the content of the request
collect = Hash . new
authorization = 'Authorization'
collect [ 'authorization' ] = authorization
create_schedule_body = CreateScheduleBody . new
collect [ 'create_schedule_body' ] = create_schedule_body
result = schedules . create_schedule ( collect )
Error Code
Error Description
400
Bad Request
401
Unauthorized/Missing Token
403
Forbidden
404
Not Found
422
Unprocessable Entity
500
Unexpected error
update_schedule_time_window_by_id
Update a TimeWindow for a Schedule.
def update_schedule_time_window_by_id ( options = Hash . new ) ; end
Parameter
Tags
Description
authorization
Required
A valid API key, in the format 'Token API_KEY'
id
Required
TODO: Add a parameter description
time_window_id
Required
TODO: Add a parameter description
update_schedule_time_window_by_id_body
Required
the content of the request
collect = Hash . new
authorization = 'Authorization'
collect [ 'authorization' ] = authorization
id = 'id'
collect [ 'id' ] = id
time_window_id = 'time_window_id'
collect [ 'time_window_id' ] = time_window_id
update_schedule_time_window_by_id_body = UpdateScheduleTimeWindowByIdBody . new
collect [ 'update_schedule_time_window_by_id_body' ] = update_schedule_time_window_by_id_body
result = schedules . update_schedule_time_window_by_id ( collect )
Error Code
Error Description
400
Bad Request
401
Unauthorized/Missing Token
403
Forbidden
404
Not Found
422
Unprocessable Entity
500
Unexpected error
get_schedules
Return all Schedules that your account has access to. Includes Schedules for your own User as well as any Users for which you are the Account Manager.
def get_schedules ( options = Hash . new ) ; end
Parameter
Tags
Description
authorization
Required
A valid API key, in the format 'Token API_KEY'
page
Optional DefaultValue
Page offset to fetch.
per_page
Optional DefaultValue
Number of results to return per page.
user_id
Optional
Retrieve Schedules owned only by this User Id. You must be authorized to manage this User Id.
collect = Hash . new
authorization = 'Authorization'
collect [ 'authorization' ] = authorization
page = 1
collect [ 'page' ] = page
per_page = 10
collect [ 'per_page' ] = per_page
user_id = 45
collect [ 'user_id' ] = user_id
result = schedules . get_schedules ( collect )
Error Code
Error Description
400
Bad Request
401
Unauthorized/Missing Token
403
Forbidden
404
Not Found
500
Unexpected error
Back to List of Controllers
ResourcesController
The singleton instance of the ResourcesController class can be accessed from the API Client.
resources = client . resources
delete_resource_by_id
Delete a Resource by id
def delete_resource_by_id ( options = Hash . new ) ; end
Parameter
Tags
Description
authorization
Required
A valid API key, in the format 'Token API_KEY'
id
Required
TODO: Add a parameter description
collect = Hash . new
authorization = 'Authorization'
collect [ 'authorization' ] = authorization
id = 'id'
collect [ 'id' ] = id
result = resources . delete_resource_by_id ( collect )
Error Code
Error Description
400
Bad Request
401
Unauthorized/Missing Token
403
Forbidden
404
Not Found
500
Unexpected error
update_resource_by_id
Update a Resource by id, with params
def update_resource_by_id ( options = Hash . new ) ; end
Parameter
Tags
Description
authorization
Required
A valid API key, in the format 'Token API_KEY'
id
Required
TODO: Add a parameter description
update_resource_by_id_body
Required
the content of the request
collect = Hash . new
authorization = 'Authorization'
collect [ 'authorization' ] = authorization
id = 'id'
collect [ 'id' ] = id
update_resource_by_id_body = UpdateResourceByIdBody . new
collect [ 'update_resource_by_id_body' ] = update_resource_by_id_body
result = resources . update_resource_by_id ( collect )
Error Code
Error Description
400
Bad Request
401
Unauthorized/Missing Token
403
Forbidden
404
Not Found
422
Unprocessable Entity
500
Unexpected error
get_resource_by_id
Return a Resource by id.
def get_resource_by_id ( options = Hash . new ) ; end
Parameter
Tags
Description
authorization
Required
A valid API key, in the format 'Token API_KEY'
id
Required
TODO: Add a parameter description
collect = Hash . new
authorization = 'Authorization'
collect [ 'authorization' ] = authorization
id = 'id'
collect [ 'id' ] = id
result = resources . get_resource_by_id ( collect )
Error Code
Error Description
400
Bad Request
401
Unauthorized/Missing Token
403
Forbidden
404
Not Found
500
Unexpected error
get_resource_things
Return all Resource Things.
def get_resource_things ( options = Hash . new ) ; end
Parameter
Tags
Description
authorization
Required
A valid API key, in the format 'Token API_KEY'
page
Optional DefaultValue
Page offset to fetch.
per_page
Optional DefaultValue
Number of results to return per page.
collect = Hash . new
authorization = 'Authorization'
collect [ 'authorization' ] = authorization
page = 1
collect [ 'page' ] = page
per_page = 10
collect [ 'per_page' ] = per_page
result = resources . get_resource_things ( collect )
Error Code
Error Description
400
Bad Request
401
Unauthorized/Missing Token
403
Forbidden
500
Unexpected error
create_resource
Create a Resource with params
def create_resource ( options = Hash . new ) ; end
Parameter
Tags
Description
authorization
Required
A valid API key, in the format 'Token API_KEY'
create_resource_body
Required
the content of the request
collect = Hash . new
authorization = 'Authorization'
collect [ 'authorization' ] = authorization
create_resource_body = CreateResourceBody . new
collect [ 'create_resource_body' ] = create_resource_body
result = resources . create_resource ( collect )
Error Code
Error Description
400
Bad Request
401
Unauthorized/Missing Token
403
Forbidden
422
Unprocessable Entity
500
Unexpected error
get_resources
Return list of Resources.
def get_resources ( options = Hash . new ) ; end
Parameter
Tags
Description
authorization
Required
A valid API key, in the format 'Token API_KEY'
page
Optional DefaultValue
Page offset to fetch.
per_page
Optional DefaultValue
Number of results to return per page.
user_id
Optional
Retrieve Resources owned only by this User Id. You must be authorized to manage this User Id.
collect = Hash . new
authorization = 'Authorization'
collect [ 'authorization' ] = authorization
page = 1
collect [ 'page' ] = page
per_page = 10
collect [ 'per_page' ] = per_page
user_id = 45
collect [ 'user_id' ] = user_id
result = resources . get_resources ( collect )
Error Code
Error Description
401
Unauthorized/Missing Token
403
Forbidden
404
Not Found
500
Unexpected error
Back to List of Controllers
PricingModelsController
The singleton instance of the PricingModelsController class can be accessed from the API Client.
pricingModels = client . pricing_models
update_pricing_model_by_id
Update a PricingModel by id, with params
def update_pricing_model_by_id ( options = Hash . new ) ; end
Parameter
Tags
Description
authorization
Required
A valid API key, in the format 'Token API_KEY'
id
Required
TODO: Add a parameter description
update_pricing_model_by_id_body
Required
the content of the request
collect = Hash . new
authorization = 'Authorization'
collect [ 'authorization' ] = authorization
id = 'id'
collect [ 'id' ] = id
update_pricing_model_by_id_body = UpdatePricingModelByIdBody . new
collect [ 'update_pricing_model_by_id_body' ] = update_pricing_model_by_id_body
result = pricingModels . update_pricing_model_by_id ( collect )
Error Code
Error Description
400
Bad Request
401
Unauthorized/Missing Token
403
Forbidden
404
Not Found
422
Unprocessable Entity
500
Unexpected error
get_pricing_model_by_id
Return a PricingModel by id.
def get_pricing_model_by_id ( options = Hash . new ) ; end
Parameter
Tags
Description
authorization
Required
A valid API key, in the format 'Token API_KEY'
id
Required
TODO: Add a parameter description
collect = Hash . new
authorization = 'Authorization'
collect [ 'authorization' ] = authorization
id = 'id'
collect [ 'id' ] = id
result = pricingModels . get_pricing_model_by_id ( collect )
Error Code
Error Description
400
Bad Request
401
Unauthorized/Missing Token
403
Forbidden
404
Not Found
500
Unexpected error
create_pricing_model
Create a PricingModel with params
def create_pricing_model ( options = Hash . new ) ; end
Parameter
Tags
Description
authorization
Required
A valid API key, in the format 'Token API_KEY'
create_pricing_model_body
Required
the content of the request
collect = Hash . new
authorization = 'Authorization'
collect [ 'authorization' ] = authorization
create_pricing_model_body = CreatePricingModelBody . new
collect [ 'create_pricing_model_body' ] = create_pricing_model_body
result = pricingModels . create_pricing_model ( collect )
Error Code
Error Description
400
Bad Request
401
Unauthorized/Missing Token
403
Forbidden
422
Unprocessable Entity
500
Unexpected error
get_pricing_models
Return list of PricingModels.
def get_pricing_models ( options = Hash . new ) ; end
Parameter
Tags
Description
authorization
Required
A valid API key, in the format 'Token API_KEY'
page
Optional DefaultValue
Page offset to fetch.
per_page
Optional DefaultValue
Number of results to return per page.
user_id
Optional
Retrieve PricingModels owned only by this User Id. You must be authorized to manage this User Id.
collect = Hash . new
authorization = 'Authorization'
collect [ 'authorization' ] = authorization
page = 1
collect [ 'page' ] = page
per_page = 10
collect [ 'per_page' ] = per_page
user_id = 136
collect [ 'user_id' ] = user_id
result = pricingModels . get_pricing_models ( collect )
Error Code
Error Description
401
Unauthorized/Missing Token
403
Forbidden
404
Not Found
500
Unexpected error
Back to List of Controllers
CategoriesController
The singleton instance of the CategoriesController class can be accessed from the API Client.
categories = client . categories
get_category_by_id
Return a Category by id.
def get_category_by_id ( options = Hash . new ) ; end
Parameter
Tags
Description
authorization
Required
A valid API key, in the format 'Token API_KEY'
id
Required
TODO: Add a parameter description
collect = Hash . new
authorization = 'Authorization'
collect [ 'authorization' ] = authorization
id = 'id'
collect [ 'id' ] = id
result = categories . get_category_by_id ( collect )
Error Code
Error Description
400
Bad Request
401
Unauthorized/Missing Token
403
Forbidden
404
Not Found
500
Unexpected error
create_category
Create a Category
def create_category ( options = Hash . new ) ; end
Parameter
Tags
Description
authorization
Required
A valid API key, in the format 'Token API_KEY'
create_category_body
Required
the content of the request
collect = Hash . new
authorization = 'Authorization'
collect [ 'authorization' ] = authorization
create_category_body = CreateCategoryBody . new
collect [ 'create_category_body' ] = create_category_body
result = categories . create_category ( collect )
Error Code
Error Description
400
Bad Request
401
Unauthorized/Missing Token
403
Forbidden
422
Unprocessable Entity
500
Unexpected error
get_categories
Return list of Categories.
def get_categories ( options = Hash . new ) ; end
Parameter
Tags
Description
authorization
Required
A valid API key, in the format 'Token API_KEY'
page
Optional DefaultValue
Page offset to fetch.
per_page
Optional DefaultValue
Number of results to return per page.
user_id
Optional
Retrieve Categories of all services provided by this User Id. You must be authorized to manage this User Id.
collect = Hash . new
authorization = 'Authorization'
collect [ 'authorization' ] = authorization
page = 1
collect [ 'page' ] = page
per_page = 10
collect [ 'per_page' ] = per_page
user_id = 136
collect [ 'user_id' ] = user_id
result = categories . get_categories ( collect )
Error Code
Error Description
400
Bad Request
401
Unauthorized/Missing Token
403
Forbidden
500
Unexpected error
Back to List of Controllers