@mft/moneyhub-api-client
Version:
Node.JS client for the Moneyhub API
32 lines • 891 B
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.default = ({ config, request }) => {
const { identityServiceUrl } = config;
const addPayLink = (body, options) => request(`${identityServiceUrl}/pay-links`, {
method: "POST",
body,
cc: {
scope: "pay_link:create",
},
options,
});
const getPayLink = ({ id }, options) => request(`${identityServiceUrl}/pay-links/${id}`, {
cc: {
scope: "pay_link:read",
},
options,
});
const getPayLinks = (params = {}, options) => request(`${identityServiceUrl}/pay-links`, {
searchParams: params,
cc: {
scope: "pay_link:read",
},
options,
});
return {
addPayLink,
getPayLink,
getPayLinks,
};
};
//# sourceMappingURL=pay-links.js.map