Condensed Consolidated Statements of Change in Convertible Preferred Stock and Shareholders' Equity (Deficit) - USD ($)
$ in Thousands
Total
Common Stock (Class A and B)
Additional Paid-in Capital
Accumulated Deficit
Accumulated Other Comprehensive Income (Loss)
Beginning balance, convertible preferred stock (in shares) at Jan. 31, 2018 67,619,377        
Beginning balance, convertible preferred stock at Jan. 31, 2018 $ 112,687        
Ending balance, convertible preferred stock (in shares) at Apr. 30, 2018 67,619,377        
Ending balance, convertible preferred stock at Apr. 30, 2018 $ 112,687        
Beginning balance, common stock (in shares) at Jan. 31, 2018   20,280,741      
Beginning balance at Jan. 31, 2018 (80,741) $ 0 $ 25,892 $ (106,633) $ 0
Increase (Decrease) in Stockholders' Equity [Roll Forward]          
Stock option exercises (in shares)   1,759,288      
Issuance of common stock under employee stock plans 1,681   1,681    
Share-based compensation expense 1,842   1,842    
Comprehensive loss (14,330)     (14,330) 0
Ending balance, common stock (in shares) at Apr. 30, 2018   22,040,029      
Ending balance at Apr. 30, 2018 $ (91,548) $ 0 29,415 (120,963) 0
Beginning balance, convertible preferred stock (in shares) at Jan. 31, 2019 0        
Beginning balance, convertible preferred stock at Jan. 31, 2019 $ 0        
Ending balance, convertible preferred stock (in shares) at Apr. 30, 2019 0        
Ending balance, convertible preferred stock at Apr. 30, 2019 $ 0        
Beginning balance, common stock (in shares) at Jan. 31, 2019 20,280,741 104,971,443      
Beginning balance at Jan. 31, 2019 $ 166,992 $ 0 327,510 (160,518) 0
Increase (Decrease) in Stockholders' Equity [Roll Forward]          
Stock option exercises (in shares)   1,406,960      
Issuance of common stock under employee stock plans 9,159   9,159    
Share-based compensation expense 6,453   6,453    
Comprehensive loss $ (19,809)     (19,809) 0
Ending balance, common stock (in shares) at Apr. 30, 2019 0 106,378,403      
Ending balance at Apr. 30, 2019 $ 162,795 $ 0 $ 343,122 $ (180,327) $ 0