freshworks / freshworks-api-sdk

Node.js client SDK for Freshworks' REST APIs, currently in beta. Supports Freshteam and Freshservice (partially).
https://developers.freshworks.com/api-sdk/
MIT License
6 stars 2 forks source link

Write main functionality in JavaScript #2

Closed kaustavdm closed 3 years ago

kaustavdm commented 3 years ago

Moved core functions to JavaScript, while retaining types using tsc, mainly by hand-crafting JSDoc comments.

Fixed all imports. Code builds with npm run build. JSDoc docs are kinda wonky (try npm run docs:sdk).

npm pack result: freshworks-freshworks-api-sdk-0.0.1.tgz.zip

npm notice 
npm notice 📦  @freshworks/freshworks-api-sdk@0.0.1
npm notice === Tarball Contents === 
npm notice 1.1kB LICENSE                          
npm notice 159B  README.md                        
npm notice 2.1kB dist/_freshteam/employee.d.ts    
npm notice 1.1kB dist/_freshteam/employee.js      
npm notice 6.5kB dist/_freshteam/job-postings.d.ts
npm notice 2.3kB dist/_freshteam/job-postings.js  
npm notice 2.9kB dist/_freshteam/time-offs.d.ts   
npm notice 4.3kB dist/_freshteam/time-offs.js     
npm notice 1.6kB dist/freshteam.d.ts              
npm notice 963B  dist/freshteam.js                
npm notice 5.0kB dist/http-client.d.ts            
npm notice 5.1kB dist/http-client.js              
npm notice 83B   dist/index.d.ts                  
npm notice 981B  dist/index.js                    
npm notice 830B  package.json                     
npm notice === Tarball Details === 
npm notice name:          @freshworks/freshworks-api-sdk          
npm notice version:       0.0.1                                   
npm notice filename:      @freshworks/freshworks-api-sdk-0.0.1.tgz
npm notice package size:  7.2 kB                                  
npm notice unpacked size: 35.0 kB                                 
npm notice shasum:        9298d08084f273669b25fd4e29b0045984c57ac5
npm notice integrity:     sha512-DkONmEhnWZ4JH[...]ykJi970QFzjww==
npm notice total files:   15                                      
npm notice 
freshworks-freshworks-api-sdk-0.0.1.tgz
kaustavdm commented 3 years ago

Closing this PR in favour of a new branch that incorporates latest design discussions.