onesignal-node-api icon indicating copy to clipboard operation
onesignal-node-api copied to clipboard

[Feature Request]: mix this.configuration and _options in api method

Open NotEvenANeko opened this issue 2 years ago • 2 comments

What's on your mind?

Mix this.configuration and _options instead of _config || this.configuration can make api easier for use.

For example I have a system which manage lots of apps, and I set userKey in the createConfiguration to manage apps. When I want to send notifications to one app, I can set the apiKey in the _options parameter, but I also need to provide parameters like baseServer, httpApi and middleware. Mix this.configuration and _options can make properties of the _options parameter optional.

Create a new DefaultApi instance every time is a way to solve this problem, but sometimes I want to make sure that only one instance exists, like using with NestJS.

Code of Conduct

  • [X] I agree to follow this project's Code of Conduct

NotEvenANeko avatar Apr 28 '23 07:04 NotEvenANeko

btw the link of the 'Code of Conduct' in the issue template is broken.

NotEvenANeko avatar Apr 28 '23 07:04 NotEvenANeko

Thank you for reporting, this request has been noted for future releases!

emawby avatar Apr 28 '23 18:04 emawby