Socket
Book a DemoInstallSign in
Socket

meo-wallet

Package Overview
Dependencies
Maintainers
1
Versions
5
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

meo-wallet

Node wrapper for MEO Wallet API

latest
Source
npmnpm
Version
0.0.4
Version published
Maintainers
1
Created
Source

meo-wallet

Node wrapper for MEO Wallet API https://developers.wallet.pt/

Usage

var wallet = require('meo-wallet');

wallet.checkout.create({
  "client": {
    "name": "some name",
    "email": "foo@bar.com",
    "address": {
      "country": "pt",
      "address":"some street",
      "city": "lisboa",
      "postalcode": "1100-000"
    }
  },
  "amount":10,
  "currency": "EUR",
  "items":[{
    "ref":123,
    "name":"Livro",
    "descr":"Um livro",
  "qt":1
  }]
}, function(error, checkout) {
  if(error) {
    console.log(error);
  }
  console.log(checkout);
});

wallet.checkout.get('153ea3e1-6fce-4e86-9c80-1169c00eae9c', function(error, checkout) {
  if(error) {
    console.log(error);
  }
  console.log(checkout);
});

wallet.checkout.delete('153ea3e1-6fce-4e86-9c80-1169c00eae9c', function(error, checkout) {
  if(error) {
    console.log(error);
  }
  console.log(checkout);
});

wallet.operations.getOperations('limit=3', function(error, operations) {
  if(error) {
    console.log(error);
  }
  console.log(operations);
});

wallet.operations.getOperation('45ff577f-3e40-5598-5eab-c235f9bb832d', function(error, operation) {
  if(error) {
    console.log(error);
  }
  console.log(operation);
});

wallet.operations.refund('45ff577f-3e40-5598-5eab-c235f9bb832d', 'full', function(error, operation) {
  if(error) {
    console.log(error);
  }
  console.log(operation);
});

FAQs

Package last updated on 14 Apr 2014

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts