aboutsummaryrefslogblamecommitdiff
path: root/src/gapi.ts
blob: 9ddf7517c98c340f2e21d636868501c4d4beb1e5 (plain) (tree)
1
2
3
4
5
6
7
8
9




                                                          
                             


                                          
                                          




                                  
                                 





                                                                

                                                                      
                                     



                                                                    






                                                                            
                                                       

                          





                                       
     
                    

 



                                                       

 






                                              

 
                                               

                                     

                                                                             





                                        









                              
                                                                 
                               

                                                                               


                                         
                                                              
                               

                                                                


                           
                                                                                      
                               
                                                                                              








                                                 
                                                                        


                                                                     
                                                                                      






                                         












                                                               
             


                                                              
         




                                      
                                




                           


                  


              























                                                                 
                                  

                  


















                                                                      

                                        










                                                                                       










                                                                     























                                                                                  














































                                                                                     





































                                                                                       
                            















                                                              
                                                                     

            

                                                                                    
                                             
                                                                                                    



                                  

                                                 











                                                                


                                                                 
                       

                                              













                                                   




                                                 




























                                                                                                      
                                                                                                                    




















                                                                                
                                                 



                                                         






                                                                              
                                                  

















                                                                                  


                                                                    



                                     


                                                                    


         
/* global chrome */

import LRU from "lru-cache";

const gapiBase = 'https://www.googleapis.com/calendar/v3';
let loggedIn: boolean = null;

enum GApiError {
    invalidSyncToken = "invalidSyncToken",
    invalidAuthToken = "invalidAuthToken",
    notLoggedIn = "notLoggedIn",
    notLoggedOut = "notLoggedOut",
    otherError = "otherError",
}

function toParams(dict: