Skip to content
This repository has been archived by the owner on Dec 2, 2022. It is now read-only.

Commit

Permalink
πŸ˜–
Browse files Browse the repository at this point in the history
  • Loading branch information
transitive-bullshit committed Jul 9, 2020
1 parent 438afdb commit a191193
Showing 1 changed file with 18 additions and 0 deletions.
18 changes: 18 additions & 0 deletions packages/saasify-provider-sdk/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,24 @@ module.exports = class SaasifyProviderSDK {
return this._baseUrl
}

// --------------------------------------------------------------------------
// Customers
// --------------------------------------------------------------------------

async getUser(userId, params = {}) {
if (!userId) {
throw new Error(
'getCustomer missing required parameter "userId" (string id)'
)
}

return this._request({
url: `/1/provider/users/${userId}`,
method: 'get',
params
}).then((res) => res.data)
}

// --------------------------------------------------------------------------
// Metered billing usage
// --------------------------------------------------------------------------
Expand Down

0 comments on commit a191193

Please sign in to comment.