1.0.0 • Published 4 years ago

beta_mondenge_api v1.0.0

Weekly downloads
4
License
CREATIVE COMMONS ...
Repository
-
Last release
4 years ago

beta_mondenge_api

BetaMondengeApi - JavaScript client for beta_mondenge_api Restful API Docs for the BetMondenge Congo DRC Android and Web Peer to Peer Waging Platform. Permission is Hereby Granted to Use this API for Commercial and Non Profit Uses Subject to the Creative Commons License Requiring you the end user to mention, credit and attribute this product and service with TralahTek LLC . COPYRIGHT: 2020 (All Rights Reserved).
This SDK is automatically generated by the Swagger Codegen project:

  • API version: v1
  • Package version: v1
  • Build package: io.swagger.codegen.languages.JavascriptClientCodegen

Installation

For Node.js

npm

To publish the library as a npm, please follow the procedure in "Publishing npm packages".

Then install it via:

npm install beta_mondenge_api --save
Local development

To use the library locally without publishing to a remote npm registry, first install the dependencies by changing into the directory containing package.json (and this README). Let's call this JAVASCRIPT_CLIENT_DIR. Then run:

npm install

Next, link it globally in npm with the following, also from JAVASCRIPT_CLIENT_DIR:

npm link

Finally, switch to the directory you want to use your beta_mondenge_api from, and run:

npm link /path/to/<JAVASCRIPT_CLIENT_DIR>

You should now be able to require('beta_mondenge_api') in javascript files from the directory you ran the last command above from.

git

If the library is hosted at a git repository, e.g. https://github.com/GIT_USER_ID/GIT_REPO_ID then install it via:

    npm install GIT_USER_ID/GIT_REPO_ID --save

For browser

The library also works in the browser environment via npm and browserify. After following the above steps with Node.js and installing browserify with npm install -g browserify, perform the following (assuming main.js is your entry file, that's to say your javascript file where you actually use this library):

browserify main.js > bundle.js

Then include bundle.js in the HTML pages.

Webpack Configuration

Using Webpack you may encounter the following error: "Module not found: Error: Cannot resolve module", most certainly you should disable AMD loader. Add/merge the following section to your webpack config:

module: {
  rules: [
    {
      parser: {
        amd: false
      }
    }
  ]
}

Getting Started

Please follow the installation instruction and execute the following JS code:

var BetaMondengeApi = require('beta_mondenge_api');

var defaultClient = BetaMondengeApi.ApiClient.instance;

// Configure API key authorization: api_key
var api_key = defaultClient.authentications['api_key'];
api_key.apiKey = "YOUR API KEY"
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//api_key.apiKeyPrefix['Authorization'] = "Token"

var api = new BetaMondengeApi.ApiApi()

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.apiAccountsList(callback);

Documentation for API Endpoints

All URIs are relative to https://betmeback.herokuapp.com/en

ClassMethodHTTP requestDescription
BetaMondengeApi.ApiApiapiAccountsListGET /api/accounts/
BetaMondengeApi.ApiApiapiAccountsReadGET /api/accounts/{id}/
BetaMondengeApi.ApiApiapiAllusersListGET /api/allusers/
BetaMondengeApi.ApiApiapiBetslipsAcceptWagerPOST /api/betslips/{id}/accept_wager/
BetaMondengeApi.ApiApiapiBetslipsCreatePOST /api/betslips/
BetaMondengeApi.ApiApiapiBetslipsListGET /api/betslips/
BetaMondengeApi.ApiApiapiBetslipsReadGET /api/betslips/{id}/
BetaMondengeApi.ApiApiapiBetslipsReceivedInvitesGET /api/betslips/received_invites/
BetaMondengeApi.ApiApiapiBetslipsRejectWagerPOST /api/betslips/{id}/reject_wager/
BetaMondengeApi.ApiApiapiBetslipsSentInvitesGET /api/betslips/sent_invites/
BetaMondengeApi.ApiApiapiDevicesCreatePOST /api/devices/
BetaMondengeApi.ApiApiapiDoB2cCreatePOST /api/do_b2c/Initiate Customer Payout for DRC's Vodacash Mpesa System Post the amount to withdrawal
BetaMondengeApi.ApiApiapiDoC2bCreatePOST /api/do_c2b/Initiate Customer Deposit for DRC's Vodacash Mpesa System.
BetaMondengeApi.ApiApiapiGamesGetThisMidweeksGET /api/games/get_this_midweeks/
BetaMondengeApi.ApiApiapiGamesGetThisMidweeksUpcomingGET /api/games/get_this_midweeks_upcoming/
BetaMondengeApi.ApiApiapiGamesGetThisMonthsGET /api/games/get_this_months/
BetaMondengeApi.ApiApiapiGamesGetThisMonthsUpcomingGET /api/games/get_this_months_upcoming/
BetaMondengeApi.ApiApiapiGamesGetThisWeekendsGET /api/games/get_this_weekends/
BetaMondengeApi.ApiApiapiGamesGetThisWeekendsUpcomingGET /api/games/get_this_weekends_upcoming/
BetaMondengeApi.ApiApiapiGamesListGET /api/games/
BetaMondengeApi.ApiApiapiGamesReadGET /api/games/{game_id}/
BetaMondengeApi.ApiApiapiGamesTodaysGET /api/games/todays/
BetaMondengeApi.ApiApiapiInviteCreatePOST /api/invite/
BetaMondengeApi.ApiApiapiLeaguesAllGamesGET /api/leagues/{league_id}/all_games/
BetaMondengeApi.ApiApiapiLeaguesListGET /api/leagues/
BetaMondengeApi.ApiApiapiLeaguesReadGET /api/leagues/{league_id}/
BetaMondengeApi.ApiApiapiLeaguesThisMonthsGamesGET /api/leagues/{league_id}/this_months_games/
BetaMondengeApi.ApiApiapiLeaguesThisMonthsUpcomingGamesGET /api/leagues/{league_id}/this_months_upcoming_games/
BetaMondengeApi.ApiApiapiLeaguesThisWeeksGamesGET /api/leagues/{league_id}/this_weeks_games/
BetaMondengeApi.ApiApiapiLeaguesThisWeeksUpcomingGamesGET /api/leagues/{league_id}/this_weeks_upcoming_games/
BetaMondengeApi.ApiApiapiLeaguesUpcomingGamesGET /api/leagues/{league_id}/upcoming_games/
BetaMondengeApi.ApiApiapiMpesaDoB2cCreatePOST /api/mpesa_do_b2c/Initiate Mpesa Customer Withdrawal for Kenya's MPESA System
BetaMondengeApi.ApiApiapiMpesaDoC2bCreatePOST /api/mpesa_do_c2b/Initiate Mpesa Customer Deposit for Kenya's MPESA System
BetaMondengeApi.ApiApiapiResultsListGET /api/results/
BetaMondengeApi.ApiApiapiResultsReadGET /api/results/{game_id}/
BetaMondengeApi.ApiApiapiResultsThisMonthGET /api/results/this_month/
BetaMondengeApi.ApiApiapiResultsThisWeekGET /api/results/this_week/
BetaMondengeApi.ApiApiapiResultsTodayGET /api/results/today/
BetaMondengeApi.ApiApiapiTeamsListGET /api/teams/
BetaMondengeApi.ApiApiapiTeamsReadGET /api/teams/{team_id}/
BetaMondengeApi.ApiApiapiTransactionsListGET /api/transactions/
BetaMondengeApi.ApiApiapiTransactionsReadGET /api/transactions/{id}/
BetaMondengeApi.ApiApiapiUsersCreatePOST /api/users/
BetaMondengeApi.ApiApiapiUsersListGET /api/users/
BetaMondengeApi.ApiApiapiUsersReadGET /api/users/{phonenumber}/
BetaMondengeApi.ApiApiapiUsersResetPasswordPOST /api/users/reset_password/
BetaMondengeApi.ApiApiapiUsersSetPasswordPOST /api/users/{phonenumber}/set_password/
BetaMondengeApi.ApiApiapiUsersWebcurrentGET /api/users/webcurrent/
BetaMondengeApi.ApiTokenAuthApiapiTokenAuthCreatePOST /api-token-auth

Documentation for Models

Documentation for Authorization

api_key

  • Type: API key
  • API key parameter name: Authorization
  • Location: HTTP header