Common Stock and Stockholders' Equity (Deficit) - Additional Information (Details)
1 Months Ended 3 Months Ended 12 Months Ended
Apr. 15, 2019
shares
Apr. 14, 2019
shares
Apr. 11, 2019
purchase_period
shares
Mar. 31, 2019
shares
Apr. 30, 2019
USD ($)
equity_incentive_plan
$ / shares
shares
Apr. 30, 2018
USD ($)
$ / shares
shares
Jan. 31, 2019
USD ($)
shares
Jun. 30, 2018
$ / shares
shares
Jan. 31, 2018
shares
Subsidiary, Sale of Stock [Line Items]                  
Number of shares issued (in shares)         0        
Number of shares outstanding (in shares)         0 36,000,534 41,273,345   36,000,534
Number of equity incentive plans | equity_incentive_plan         2        
Number of shares authorized for grant (in shares)         12,431,920   23,929,932    
Options granted (in shares)       3,041,000 3,682,821        
Number of shares available for grant (in shares)         12,431,920   2,221,216    
Weighted average grant date fair value of stock options (in dollars per share) | $ / shares         $ 10.58 $ 3.63      
Aggregate intrinsic value of stock options exercised | $         $ 19,900,000 $ 2,800,000      
Stock-based compensation expense | $         4,812,000 $ 3,157,000      
Unrecognized compensation cost related to unvested stock options | $         $ 64,200,000   $ 30,600,000    
Unrecognized compensation cost related to unvested stock options, period for recognition         3 years 8 months 12 days   2 years 8 months 12 days    
Common stock                  
Subsidiary, Sale of Stock [Line Items]                  
Number of shares as a result of conversion (in shares)   41,273,345     41,273,345        
Conversion ratio   1              
Number of shares called by warrant               648,092  
Exercise price (in dollars per share) | $ / shares               $ 0.01  
Exercise of common stock warrants (in shares) 647,822       737,807        
Stock options                  
Subsidiary, Sale of Stock [Line Items]                  
Expiration period         10 years        
Vesting period         4 years        
ESPP                  
Subsidiary, Sale of Stock [Line Items]                  
Number of shares authorized for grant (in shares)     1,850,000            
Offering period     24 months            
Number of purchase periods within each offering period | purchase_period     4            
Purchase period     6 months            
Purchase price as a percentage of fair market value of stock on the offering date or the purchase date     85.00%            
Stock-based compensation expense | $         $ 400,000        
Amount withheld on behalf of employees for future purchase | $         $ 0        
Shares purchased (in shares)         0        
50% vest over four years from grant date | Stock options                  
Subsidiary, Sale of Stock [Line Items]                  
Vesting period       4 years          
Vesting percentage       50.00%          
50% vest over five years from grant date | Stock options                  
Subsidiary, Sale of Stock [Line Items]                  
Vesting period       5 years          
Vesting percentage       50.00%