Module: BridgeAPI::Client::ProgramEnrollment
- Defined in:
- lib/bridge_api/client/program_enrollment.rb
Overview
WARNING: the API endpoint for program enrollments is currently undocumented in the Bridge API. It’s possible that it might change or be removed in the future, causing this to break.
Instance Method Summary collapse
- #add_program_enrollment(program_id, params = {}) ⇒ Object
- #delete_program_enrollment(program_id, enrollment_id, params = {}) ⇒ Object
- #get_all_program_enrollments(program_id, params = {}) ⇒ Object
- #update_program_enrollment(program_id, program_enrollment_id, params = {}) ⇒ Object
Instance Method Details
#add_program_enrollment(program_id, params = {}) ⇒ Object
10 11 12 |
# File 'lib/bridge_api/client/program_enrollment.rb', line 10 def add_program_enrollment(program_id, params = {}) post("#{API_PATH}#{AUTHOR_PATH}#{PROGRAM_PATH}/#{program_id}#{PROGRAM_ENROLLMENT_PATH}", params) end |
#delete_program_enrollment(program_id, enrollment_id, params = {}) ⇒ Object
18 19 20 |
# File 'lib/bridge_api/client/program_enrollment.rb', line 18 def delete_program_enrollment(program_id, enrollment_id, params = {}) delete("#{API_PATH}#{AUTHOR_PATH}#{PROGRAM_PATH}/#{program_id}#{PROGRAM_ENROLLMENT_PATH}/#{enrollment_id}", params) end |
#get_all_program_enrollments(program_id, params = {}) ⇒ Object
22 23 24 |
# File 'lib/bridge_api/client/program_enrollment.rb', line 22 def get_all_program_enrollments(program_id, params = {}) get("#{API_PATH}#{AUTHOR_PATH}#{PROGRAM_PATH}/#{program_id}#{PROGRAM_ENROLLMENT_PATH}", params) end |
#update_program_enrollment(program_id, program_enrollment_id, params = {}) ⇒ Object
14 15 16 |
# File 'lib/bridge_api/client/program_enrollment.rb', line 14 def update_program_enrollment(program_id, program_enrollment_id, params = {}) put("#{API_PATH}#{AUTHOR_PATH}#{PROGRAM_PATH}/#{program_id}#{PROGRAM_ENROLLMENT_PATH}/#{program_enrollment_id}", params) end |