Sha256: 447646e97db2ff47c95fa18bfc0bdb31b616b8f520992d1b1c84f15b4ef8533e

Contents?: true

Size: 1.78 KB

Versions: 6

Compression:

Stored size: 1.78 KB

Contents

*This project is currently in **Beta**. Please open up an issue [here](https://github.com/mxenabled/mx-platform-ruby/issues) to report issues using the MX Platform API Ruby Library.*

# {{gemName}}

{{moduleName}} - the Ruby gem for the {{appName}}

{{#appDescriptionWithNewLines}}
{{{.}}}
{{/appDescriptionWithNewLines}}

This SDK is automatically generated by the [OpenAPI Generator](https://openapi-generator.tech) project:

- Package version: {{gemVersion}}

## Installation

Add this line to your application's Gemfile:

```ruby
gem 'mx-platform-ruby'
```

And then execute:
```shell
$ bundle
```

Or install it yourself with:
```shell
$ gem install mx-platform-ruby
```

## Getting Started

In order to make requests, you will need to [sign up](https://dashboard.mx.com/sign_up) for the MX Platform API and get a `Client ID` and `API Key`.

Please follow the [installation](#installation) procedure and then run the following code:

```ruby
# Load the gem
require 'mx-platform-ruby'

# setup authorization
MxPlatformRuby.configure do |config|
  # Configure HTTP basic authorization
  config.username = 'Your Client ID from https://dashboard.mx.com'
  config.password = 'Your API Key from https://dashboard.mx.com'

  # Configure server. 0 for production, 1 for development
  config.server_index = 1
end

api_instance = MxPlatformRuby::MxPlatformApi.new
user_create_request_body = MxPlatformRuby::UserCreateRequestBody.new(
  user: MxPlatformRuby::UserCreateRequest.new(
    metadata: "Creating a user!"
  )
)

begin
  # Create user
  result = api_instance.create_user(user_create_request_body)
  p result
rescue MxPlatformRuby::ApiError => e
  puts "Error when calling MxPlatformApi->create_user: #{e}"
end
```

## Documentation

Additional examples for the API endpoints can be found [here](docs/MxPlatformApi.md).

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
mx-platform-ruby-0.6.0 openapi/templates/README.mustache
mx-platform-ruby-0.5.0 openapi/templates/README.mustache
mx-platform-ruby-0.4.2 openapi/templates/README.mustache
mx-platform-ruby-0.4.1 openapi/templates/README.mustache
mx-platform-ruby-0.4.0 openapi/templates/README.mustache
mx-platform-ruby-0.3.2 openapi/templates/README.mustache