{"id":23047375,"url":"https://github.com/moceanapi/mocean-sdk-nodejs","last_synced_at":"2025-08-15T00:33:58.100Z","repository":{"id":48314095,"uuid":"138827106","full_name":"MoceanAPI/mocean-sdk-nodejs","owner":"MoceanAPI","description":"✉📲 SDK Library for NodeJS to send SMS for FREE using MoceanAPI sms solution.","archived":false,"fork":false,"pushed_at":"2023-03-24T10:16:04.000Z","size":167,"stargazers_count":1,"open_issues_count":7,"forks_count":4,"subscribers_count":0,"default_branch":"master","last_synced_at":"2025-07-30T14:52:10.398Z","etag":null,"topics":["moceanapi","nodejs","sms","sms-api","sms-client","sms-messages"],"latest_commit_sha":null,"homepage":"https://moceanapi.com/","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/MoceanAPI.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.txt","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2018-06-27T03:52:08.000Z","updated_at":"2023-03-24T03:43:15.000Z","dependencies_parsed_at":"2024-10-24T06:20:36.446Z","dependency_job_id":"27335daa-d90a-434f-bf57-fbb11805f03f","html_url":"https://github.com/MoceanAPI/mocean-sdk-nodejs","commit_stats":{"total_commits":81,"total_committers":8,"mean_commits":10.125,"dds":"0.19753086419753085","last_synced_commit":"4fa4aaa0ce704faee63bdbcc2d520ba342564d93"},"previous_names":[],"tags_count":6,"template":false,"template_full_name":null,"purl":"pkg:github/MoceanAPI/mocean-sdk-nodejs","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MoceanAPI%2Fmocean-sdk-nodejs","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MoceanAPI%2Fmocean-sdk-nodejs/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MoceanAPI%2Fmocean-sdk-nodejs/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MoceanAPI%2Fmocean-sdk-nodejs/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/MoceanAPI","download_url":"https://codeload.github.com/MoceanAPI/mocean-sdk-nodejs/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MoceanAPI%2Fmocean-sdk-nodejs/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":270505628,"owners_count":24596501,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-08-14T02:00:10.309Z","response_time":75,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["moceanapi","nodejs","sms","sms-api","sms-client","sms-messages"],"created_at":"2024-12-15T22:33:23.030Z","updated_at":"2025-08-15T00:33:57.472Z","avatar_url":"https://github.com/MoceanAPI.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"MoceanAPI Client Library for NodeJS \n============================\n[![npm version](https://img.shields.io/npm/v/mocean-sdk.svg)](https://www.npmjs.com/package/mocean-sdk)\n[![build status](https://img.shields.io/travis/com/MoceanAPI/mocean-sdk-nodejs.svg)](https://travis-ci.com/MoceanAPI/mocean-sdk-nodejs)\n[![codacy](https://img.shields.io/codacy/grade/988872ff78ee4429a1780aa6359886a0.svg)](https://app.codacy.com/project/MoceanAPI/mocean-sdk-nodejs/dashboard)\n[![license](https://img.shields.io/npm/l/mocean-sdk.svg)](https://www.npmjs.com/package/mocean-sdk)\n[![total downloads](https://img.shields.io/npm/dt/mocean-sdk.svg)](https://www.npmjs.com/package/mocean-sdk)  \n\nThis is the NodeJS client library for use Mocean's API. To use this, you'll need a Mocean account. Sign up [for free at \nmoceanapi.com][signup].\n\n * [Installation](#installation)\n * [Usage](#usage)\n * [Example](#example)\n\n## Installation\n\nTo use the client library you'll need to have [created a Mocean account][signup]. \n\nTo install the NodeJS client library using Node Package Manager (NPM).\n\n```bash\nnpm install mocean-sdk\n```\n\n## Usage\n\nCreate a client with your API key and secret:\n\n```javascript\nconst client = require('mocean-sdk');\n\nvar token = new client.Client('API_KEY_HERE','API_SECRET_HERE');\nvar mocean = new client.Mocean(token);\n```\n\n## Example\n\nTo use [Mocean's SMS API][doc_sms] to send an SMS message, call the `mocean.sms.send()` method.\n\nThe API can be called directly, using a simple array of parameters, the keys match the [parameters of the API][doc_sms].\n\n```javascript\nmocean.sms()\n    .send({\n        'mocean-from': 'MOCEAN',\n        'mocean-to': '60123456789',\n        'mocean-text': 'Hello World'\n    }, function(err, res) {\n        if (err) throw err;\n\n        console.log(res);\n    });\n```\n\n### Extras\n\nThis library support both `callbacks` and `promises`  \nTo use `callbacks`, simple pass the callback function in second parameter like example above  \nFor `promises`, refer to the example below\n```javascript\nconst promise = mocean.sms()\n    .send({\n        'mocean-from': 'MOCEAN',\n        'mocean-to': '60123456789',\n        'mocean-text': 'Hello World'\n    });\n\npromise.then(res =\u003e {\n    console.log(res);\n});\n\npromise.catch(err =\u003e {\n    throw err;\n});\n```\n\n## Documentation\n\nKindly visit [MoceanApi Docs][doc_main] for more usage\n\nLicense\n-------\n\nThis library is released under the [MIT License][license]\n\n[signup]: https://dashboard.moceanapi.com/register?medium=github\u0026campaign=nodejs-sdk\n[doc_main]: https://moceanapi.com/docs/?javascript\n[doc_sms]: https://moceanapi.com/docs/?javascript#send-sms\n[license]: LICENSE.txt\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmoceanapi%2Fmocean-sdk-nodejs","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmoceanapi%2Fmocean-sdk-nodejs","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmoceanapi%2Fmocean-sdk-nodejs/lists"}