npm

pipedrive-api
TypeScript icon, indicating that this package has built-in type declarations

0.1.21 • Public • Published

Pipedrive OAuth API Wrapper

IN DEVELOPMENT - VERY FEW ENDPOINTS IMPLEMENTED!

An early stage library for interfacing with Pipedrive's OAuth API and auto refreshes tokens for you.

Usage

Typescript

import Connection from 'pipedrive-api';
const pipedriveConnection = new Connection({
    clientId: '432424',
    clientSecret: '2354tgf234g43g43'
});

await pipedriveConnection.oauth.getToken(code, redirectUri);
const deals = await pipedriveConnection.endpoints('Deals');
await deals.all();
);
import Connection from 'pipedrive-api';
const pipedriveConnection = new Connection({
    clientId: '432424',
    clientSecret: '2354tgf234g43g43',
    lastKnownAuthState: {
        accessToken: 't2g423g3',
        refreshToken: '32f43g43g44g43g',
        expirationTime: '2019-04-04 01:01:01',
    }
});
const deals = await pipedriveConnection.endpoints('Deals');
await deals.all();
);

Readme

Keywords

none

Package Sidebar

Install

npm i pipedrive-api

Weekly Downloads

2

Version

0.1.21

License

MIT

Unpacked Size

91 kB

Total Files

23

Last publish

Collaborators

  • mattscamp