Module: Tacokit::Client::Organizations
- Included in:
- Tacokit::Client
- Defined in:
- lib/tacokit/client/organizations.rb
Instance Method Summary collapse
-
#create_organization(display_name, options = {}) ⇒ Object
POST /1/organizations.
-
#delete_organization(org_id) ⇒ Object
DELETE /1/organizations/[idOrg or name].
-
#organization(org_id, options = nil) ⇒ Object
GET /1/organizations/[idOrg or name].
- #organization_path(*paths) ⇒ Object
-
#organization_resource(org_id, resource, *paths) ⇒ Object
GET /1/organizations/[idOrg or name]/ actions boards boards/ deltas members members/ members//cards membersInvited membersInvited/ memberships memberships/.
-
#update_organization(org_id, options = {}) ⇒ Object
PUT /1/organizations/[idOrg or name].
Instance Method Details
#create_organization(display_name, options = {}) ⇒ Object
POST /1/organizations
50 51 52 |
# File 'lib/tacokit/client/organizations.rb', line 50 def create_organization(display_name, = {}) post organization_path, .merge(display_name: display_name) end |
#delete_organization(org_id) ⇒ Object
DELETE /1/organizations/[idOrg or name]
57 58 59 |
# File 'lib/tacokit/client/organizations.rb', line 57 def delete_organization(org_id) delete organization_path(org_id) end |
#organization(org_id, options = nil) ⇒ Object
GET /1/organizations/[idOrg or name]
5 6 7 |
# File 'lib/tacokit/client/organizations.rb', line 5 def organization(org_id, = nil) get organization_path(org_id), end |
#organization_path(*paths) ⇒ Object
68 69 70 |
# File 'lib/tacokit/client/organizations.rb', line 68 def organization_path(*paths) path_join "organizations", *paths end |
#organization_resource(org_id, resource, *paths) ⇒ Object
GET /1/organizations/[idOrg or name]/ actions boards boards/ deltas members members/ members//cards membersInvited membersInvited/ memberships memberships/
21 22 23 24 |
# File 'lib/tacokit/client/organizations.rb', line 21 def organization_resource(org_id, resource, *paths) paths, = (camp(resource), *paths) get organization_path(org_id, *paths), end |
#update_organization(org_id, options = {}) ⇒ Object
PUT /1/organizations/[idOrg or name]
27 28 29 |
# File 'lib/tacokit/client/organizations.rb', line 27 def update_organization(org_id, = {}) put organization_path(org_id), end |