diff --git a/lib/caido/helpers/automate.rb b/lib/caido/helpers/automate.rb new file mode 100644 index 0000000..a0373af --- /dev/null +++ b/lib/caido/helpers/automate.rb @@ -0,0 +1,30 @@ +# frozen_string_literal: true + +module Caido + # Instance class + class Instance + def automate_session(id) + query("query{ + automateSession(id: \"#{id}\"){ + id + name + raw + createdAt + } + }")['automateSession'] + end + + def automate_sessions + query('query{ + automateSessions{ + nodes{ + id + name + raw + createdAt + } + } + }')['automateSessions'] + end + end +end diff --git a/lib/caido/helpers/example.rb b/lib/caido/helpers/example.rb deleted file mode 100644 index d2f7ad5..0000000 --- a/lib/caido/helpers/example.rb +++ /dev/null @@ -1,11 +0,0 @@ -# frozen_string_literal: true - -module Caido - # Instance class - class Instance - def example_helper - # This is a example helper - 'test' - end - end -end