Have ideas to improve npm?Join in the discussion! »

    ghasedak-node

    2.0.0 • Public • Published

    Ghasedak sms webservice package for nodejs.

    install

    You can simply install and use ghasedak nodejs library from npm:

    npm install --save ghasedak-node

    or from yarn:

    yarn install ghasedak-node

    usage

    Import ghasedak package:

    const Ghasedak = require("ghasedak");

    You need a Ghasedak account. Register and get your API key.

    Create an instance from Ghasedak with your API key:

    let ghasedak = Ghasedak(
      "3ef8539ba50c06b2a11d674c8a7ded7d7360d7b090b5146ff0761e8d9927bd31"
    );

    with promise

    ghasedak
      .send({
        message: "Hello World!",
        receptor: "09xxxxxxxxx",
        linenumber: "300002525"
      })
      .then(res => {
        // ... check documentation for response type
        // https://ghasedak.io/docs
      })
      .catch(error => {});

    with async/await

    async () => {
      try {
        await ghasedak.send({
          message: "Hello World!",
          receptor: "09xxxxxxxxx",
          linenumber: "300002525"
        });
      } catch (e) {}
    };

    Keywords

    none

    Install

    npm i ghasedak-node

    DownloadsWeekly Downloads

    0

    Version

    2.0.0

    License

    MIT

    Unpacked Size

    6.2 kB

    Total Files

    4

    Last publish

    Collaborators

    • avatar