Skip to content

Latest commit

 

History

History
44 lines (27 loc) · 1.4 KB

README.md

File metadata and controls

44 lines (27 loc) · 1.4 KB

PoShPal

THIS MODULE IS UNDER DEVELOPMENT. Use at your own risk.

This module is designed to work with the PayPal API. It is under development (PRs welcome!) and currently supports authentication and retrieving order information. Nothing special yet.

Only an experimental build has been done with some minor testing.

If you would like to contribute to PoShPal, refer CONTRIBUTING.md

How to set up

Download or clone this repo and:

Import-Module $ModulePath\src\PoShPal.psm1

Before you can use this module, you must first have a PayPall account and create an application here: https://developer.paypal.com/developer/applications

You will need to open that application, switch to the 'Live' version and collect the 'Client ID' and 'Secret' from that screen.

How to authenticate

With the above mentioned information in hand, get a user token:

Get-PayPalAccessToken -ClientID $ClientID -ClientSecret $ClientSecret

This will store your credentials securely in the registry and in a global variable available to the other cmdlets.

How to query

To get information on a single sale from PayPal (you being the seller):

Get-PayPalSale -SaleID 'XXXXXXXXXXXXXXXXX'

Or to query your transaction history for the past week:

Get-PayPalTransactions -StartDate (Get-Date).AddDays(-7)