How to use the @discoin/scambio.default function in @discoin/scambio

To help you get started, we’ve selected a few @discoin/scambio examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github dice-discord / bot / src / commands / economy / discoin-rates.js View on Github external
You may obtain a copy of the License at

    http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
*/

const SentryCommand = require("../../structures/SentryCommand");
const { MessageEmbed } = require("discord.js");
const logger = require("../../util/logger").scope("command", "discoin rates");
const { stripIndents } = require("common-tags");
const Discoin = require("@discoin/scambio").default;

module.exports = class DiscoinRatesCommand extends SentryCommand {
  constructor(client) {
    super(client, {
      name: "discoin-rates",
      group: "economy",
      memberName: "discoin-rates",
      description: "Lists the conversion rates for Discoin currencies.",
      aliases: ["rates", "conversion-rates", "convert-rates"],
      clientPermissions: ["EMBED_LINKS"],
      throttling: {
        usages: 1,
        duration: 10
      }
    });
  }
github dice-discord / bot / src / commands / economy / convert-oats.js View on Github external
http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
*/

const SentryCommand = require("../../structures/SentryCommand");
const config = require("../../config");
const discoin = require("../../util/discoin");
const logger = require("../../util/logger").scope("command", "convert oats");
const database = require("../../util/database");
const Discoin = require("@discoin/scambio").default;

module.exports = class ConvertOatsCommand extends SentryCommand {
  constructor(client) {
    super(client, {
      name: "convert-oats",
      group: "economy",
      memberName: "convert-oats",
      description: "Converts oats to another bot's currency.",
      details: "Use the `discoin-rates` command to see all currencies",
      aliases: ["convert", "convert-currencies", "exchange-oats", "exchange", "exchange-currencies", "discoin"],
      examples: ["convert-oats 500 dts"],
      clientPermissions: ["EMBED_LINKS"],
      args: [
        {
          key: "amount",
          prompt: "How many oats do you want to convert to another Discoin currency?",

@discoin/scambio

[![npm version](https://img.shields.io/npm/v/@discoin/scambio)](https://www.npmjs.com/package/@discoin/scambio) [![codecov](https://codecov.io/gh/Discoin/scambio/branch/merge/graph/badge.svg)](https://codecov.io/gh/Discoin/scambio) [![MIT license](https:/

MIT
Latest version published 4 years ago

Package Health Score

51 / 100
Full package analysis