Orbit Members Helper Library for Ruby
Orbit API helper library for Ruby.
This client can create, read, update and delete members and their identities in your Orbit workspace.
Package Usage
Installation
To install this integration in a standalone app, add the gem to your Gemfile
:
gem "orbit_members"
Then, run bundle install
from your terminal.
Usage
Create a Member
To create a member:
OrbitMembers::Request.new(
api_key: # Your Orbit API key,
workspace_id: # Your Orbit workspace ID,
action: "create_member",
body: # The custom activity object in JSON format, see Orbit API docs for reference
)
Update a Member
To update a member:
OrbitMembers::Request.new(
api_key: # Your Orbit API key,
workspace_id: # Your Orbit workspace ID,
action: "update_member",
member_id: # The ID of the member,
body: # The custom activity object in JSON format, see Orbit API docs for reference
)
Delete a Member
To delete a member:
OrbitMembers::Request.new(
api_key: # Your Orbit API key,
workspace_id: # Your Orbit workspace ID,
action: "delete_member",
member_id: # The ID of the member
)
List Members in a Workspace
To list members in a workspace:
OrbitMembers::Request.new(
api_key: # Your Orbit API key,
workspace_id: # Your Orbit workspace ID,
action: "list_members",
filters: # Any filters on the request in JSON format, see Orbit API docs for reference
)
Get Specific Member
To get a specific member:
OrbitMembers::Request.new(
api_key: # Your Orbit API key,
workspace_id: # Your Orbit workspace ID,
action: "get_member",
member_id: # The ID of the member
)
Get Member by an Identity
To find a member by an identity:
OrbitMembers::Request.new(
api_key: # Your Orbit API key,
workspace_id: # Your Orbit workspace ID,
action: "find_member_by_identity",
member_id: # The ID of the member,
filters: # Identity filter to find by, see Orbit API docs for reference
)
Add an Identity to a Member
To add an identity to a member:
OrbitMembers::Request.new(
api_key: # Your Orbit API key,
workspace_id: # Your Orbit workspace ID,
action: "add_identity",
member_id: # The ID of the member,
filters: # The new identity body in JSON format, see Orbit API docs for reference
)
Remove an Identity from a Member
To remove an identity from a member:
OrbitMembers::Request.new(
api_key: # Your Orbit API key,
workspace_id: # Your Orbit workspace ID,
action: "remove_identity",
member_id: # The ID of the member,
filters: # The identity to remove in JSON format, see Orbit API docs for reference
)
For details on the data structures the Orbit API expects, refer to the Orbit API Documentation.
Contributing
We 💜 contributions from everyone! Check out the Contributing Guidelines for more information.
License
This is available as open source under the terms of the MIT License.
Code of Conduct
This project uses the Contributor Code of Conduct. We ask everyone to please adhere by its guidelines.