GithubHelp home page GithubHelp logo

onesignal-ruby-client's Introduction

Welcome to the official OneSignal Ruby Client ๐Ÿ‘‹

Gem Version

Documentation Maintenance Twitter: onesignal

OneSignal - the Ruby gem for the OneSignal

A powerful way to send personalized messages at scale and build effective customer engagement strategies. Learn more at onesignal.com

This SDK is automatically generated by the OpenAPI Generator project:

OneSignal is a simple ruby wrapper for the OneSignal API.

๐Ÿ–ค RubyGems

๐Ÿšง In Beta ๐Ÿšง

Installation

Add this line to your application's Gemfile:

gem 'onesignal', '~> 1.0.0.beta1'

And then execute:

$ bundle

Or install it yourself as:

$ gem install onesignal --pre

Or install from Github: $ gem "onesignal", '~> 1.0.0.beta1', git: 'git://github.com/OneSignal/onesignal-ruby-client.git'

Getting Started

Please follow the installation procedure and then run the following code:

require 'time'
require 'onesignal'
# setup authorization
OneSignal.configure do |config|
  # Configure Bearer authorization: app_key
  config.app_key = 'YOUR BEARER TOKEN' # Change this
end

api_instance = OneSignal::DefaultApi.new
notification = OneSignal::Notification.new({app_id: 'YOUR APP ID'}) # Notification

begin
  # Create notification
  result = api_instance.create_notification(notification)
  p result
rescue OneSignal::ApiError => e
  puts "Error when calling DefaultApi->create_notification: #{e}"
end

Documentation for API Endpoints

All URIs are relative to https://onesignal.com/api/v1

Class Method HTTP request Description
OneSignal::DefaultApi cancel_notification DELETE /notifications/{notification_id} Stop a scheduled or currently outgoing notification
OneSignal::DefaultApi create_app POST /apps Create an app
OneSignal::DefaultApi create_notification POST /notifications Create notification
OneSignal::DefaultApi create_player POST /players Add a device
OneSignal::DefaultApi create_segments POST /apps/{app_id}/segments Create Segments
OneSignal::DefaultApi delete_player DELETE /players/{player_id} Delete a user record
OneSignal::DefaultApi delete_segments DELETE /apps/{app_id}/segments/{segment_id} Delete Segments
OneSignal::DefaultApi export_players POST /players/csv_export?app_id={app_id} CSV export
OneSignal::DefaultApi get_app GET /apps/{app_id} View an app
OneSignal::DefaultApi get_apps GET /apps View apps
OneSignal::DefaultApi get_notification GET /notifications/{notification_id} View notification
OneSignal::DefaultApi get_notification_history POST /notifications/{notification_id}/history Notification History
OneSignal::DefaultApi get_notifications GET /notifications View notifications
OneSignal::DefaultApi get_outcomes GET /apps/{app_id}/outcomes View Outcomes
OneSignal::DefaultApi get_player GET /players/{player_id} View device
OneSignal::DefaultApi get_players GET /players View devices
OneSignal::DefaultApi update_app PUT /apps/{app_id} Update an app
OneSignal::DefaultApi update_player PUT /players/{player_id} Edit device
OneSignal::DefaultApi update_player_tags PUT /apps/{app_id}/users/{external_user_id} Edit tags with external user id

Documentation for Models

Documentation for Authorization

app_key

  • Type: Bearer authentication

user_key

  • Type: Bearer authentication

License

The gem is available as open source under the terms of the MIT License.

Author

๐Ÿค Contributing

Contributions, issues and feature requests are welcome!
Feel free to check issues page.

Show your support

Give a โญ๏ธ if this project helped you!

๐Ÿ“ License

Copyright ยฉ 2022 OneSignal.
This project is MIT licensed.

onesignal-ruby-client's People

Contributors

rgomezp avatar jbender avatar sidorchukandrew avatar jmadler avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.