Fair Value Measurements - Assets Measured at Fair Value on a Recurring Basis (Details) - USD ($) $ in Thousands | Oct. 31, 2023 | Apr. 30, 2023 |
Available-for-sale marketable securities: | | |
Total cash equivalents and available-for-sale marketable securities | $ 741,317 | $ 717,717 |
Money market funds | | |
Cash equivalents: | | |
Estimated Fair Value | 104,258 | 75,293 |
U.S. treasury securities | | |
Cash equivalents: | | |
Estimated Fair Value | 1,989 | 0 |
Available-for-sale marketable securities: | | |
Available-for-sale marketable securities, fair value | 4,921 | 27,397 |
Certificates of deposit | | |
Cash equivalents: | | |
Estimated Fair Value | 0 | 2,000 |
Available-for-sale marketable securities: | | |
Available-for-sale marketable securities, fair value | 69,547 | 61,025 |
Commercial paper | | |
Cash equivalents: | | |
Estimated Fair Value | 21,810 | 112,851 |
Available-for-sale marketable securities: | | |
Available-for-sale marketable securities, fair value | 228,509 | 184,230 |
U.S. government agencies securities | | |
Available-for-sale marketable securities: | | |
Available-for-sale marketable securities, fair value | 58,564 | 75,674 |
Yankee bonds | | |
Available-for-sale marketable securities: | | |
Available-for-sale marketable securities, fair value | 2,239 | 0 |
Corporate debt securities | | |
Available-for-sale marketable securities: | | |
Available-for-sale marketable securities, fair value | 249,480 | 179,247 |
Fair Value, Recurring | | |
Available-for-sale marketable securities: | | |
Total cash equivalents and available-for-sale marketable securities | 741,317 | 717,717 |
Fair Value, Recurring | Money market funds | | |
Cash equivalents: | | |
Estimated Fair Value | 104,258 | 75,293 |
Fair Value, Recurring | U.S. treasury securities | | |
Cash equivalents: | | |
Estimated Fair Value | 1,989 | 0 |
Available-for-sale marketable securities: | | |
Available-for-sale marketable securities, fair value | 4,921 | 27,397 |
Fair Value, Recurring | Certificates of deposit | | |
Cash equivalents: | | |
Estimated Fair Value | 0 | 2,000 |
Available-for-sale marketable securities: | | |
Available-for-sale marketable securities, fair value | 69,547 | 61,025 |
Fair Value, Recurring | Commercial paper | | |
Cash equivalents: | | |
Estimated Fair Value | 21,810 | 112,851 |
Available-for-sale marketable securities: | | |
Available-for-sale marketable securities, fair value | 228,509 | 184,230 |
Fair Value, Recurring | U.S. government agencies securities | | |
Available-for-sale marketable securities: | | |
Available-for-sale marketable securities, fair value | 58,564 | 75,674 |
Fair Value, Recurring | Yankee bonds | | |
Available-for-sale marketable securities: | | |
Available-for-sale marketable securities, fair value | 2,239 | 0 |
Fair Value, Recurring | Corporate debt securities | | |
Available-for-sale marketable securities: | | |
Available-for-sale marketable securities, fair value | 249,480 | 179,247 |
Fair Value, Recurring | Level 1 | | |
Available-for-sale marketable securities: | | |
Total cash equivalents and available-for-sale marketable securities | 104,258 | 75,293 |
Fair Value, Recurring | Level 1 | Money market funds | | |
Cash equivalents: | | |
Estimated Fair Value | 104,258 | 75,293 |
Fair Value, Recurring | Level 1 | U.S. treasury securities | | |
Cash equivalents: | | |
Estimated Fair Value | 0 | 0 |
Available-for-sale marketable securities: | | |
Available-for-sale marketable securities, fair value | 0 | 0 |
Fair Value, Recurring | Level 1 | Certificates of deposit | | |
Cash equivalents: | | |
Estimated Fair Value | 0 | 0 |
Available-for-sale marketable securities: | | |
Available-for-sale marketable securities, fair value | 0 | 0 |
Fair Value, Recurring | Level 1 | Commercial paper | | |
Cash equivalents: | | |
Estimated Fair Value | 0 | 0 |
Available-for-sale marketable securities: | | |
Available-for-sale marketable securities, fair value | 0 | 0 |
Fair Value, Recurring | Level 1 | U.S. government agencies securities | | |
Available-for-sale marketable securities: | | |
Available-for-sale marketable securities, fair value | 0 | 0 |
Fair Value, Recurring | Level 1 | Yankee bonds | | |
Available-for-sale marketable securities: | | |
Available-for-sale marketable securities, fair value | 0 | 0 |
Fair Value, Recurring | Level 1 | Corporate debt securities | | |
Available-for-sale marketable securities: | | |
Available-for-sale marketable securities, fair value | 0 | 0 |
Fair Value, Recurring | Level 2 | | |
Available-for-sale marketable securities: | | |
Total cash equivalents and available-for-sale marketable securities | 637,059 | 642,424 |
Fair Value, Recurring | Level 2 | Money market funds | | |
Cash equivalents: | | |
Estimated Fair Value | 0 | 0 |
Fair Value, Recurring | Level 2 | U.S. treasury securities | | |
Cash equivalents: | | |
Estimated Fair Value | 1,989 | 0 |
Available-for-sale marketable securities: | | |
Available-for-sale marketable securities, fair value | 4,921 | 27,397 |
Fair Value, Recurring | Level 2 | Certificates of deposit | | |
Cash equivalents: | | |
Estimated Fair Value | 0 | 2,000 |
Available-for-sale marketable securities: | | |
Available-for-sale marketable securities, fair value | 69,547 | 61,025 |
Fair Value, Recurring | Level 2 | Commercial paper | | |
Cash equivalents: | | |
Estimated Fair Value | 21,810 | 112,851 |
Available-for-sale marketable securities: | | |
Available-for-sale marketable securities, fair value | 228,509 | 184,230 |
Fair Value, Recurring | Level 2 | U.S. government agencies securities | | |
Available-for-sale marketable securities: | | |
Available-for-sale marketable securities, fair value | 58,564 | 75,674 |
Fair Value, Recurring | Level 2 | Yankee bonds | | |
Available-for-sale marketable securities: | | |
Available-for-sale marketable securities, fair value | 2,239 | 0 |
Fair Value, Recurring | Level 2 | Corporate debt securities | | |
Available-for-sale marketable securities: | | |
Available-for-sale marketable securities, fair value | 249,480 | 179,247 |
Fair Value, Recurring | Level 3 | | |
Available-for-sale marketable securities: | | |
Total cash equivalents and available-for-sale marketable securities | 0 | 0 |
Fair Value, Recurring | Level 3 | Money market funds | | |
Cash equivalents: | | |
Estimated Fair Value | 0 | 0 |
Fair Value, Recurring | Level 3 | U.S. treasury securities | | |
Cash equivalents: | | |
Estimated Fair Value | 0 | 0 |
Available-for-sale marketable securities: | | |
Available-for-sale marketable securities, fair value | 0 | 0 |
Fair Value, Recurring | Level 3 | Certificates of deposit | | |
Cash equivalents: | | |
Estimated Fair Value | 0 | 0 |
Available-for-sale marketable securities: | | |
Available-for-sale marketable securities, fair value | 0 | 0 |
Fair Value, Recurring | Level 3 | Commercial paper | | |
Cash equivalents: | | |
Estimated Fair Value | 0 | 0 |
Available-for-sale marketable securities: | | |
Available-for-sale marketable securities, fair value | 0 | 0 |
Fair Value, Recurring | Level 3 | U.S. government agencies securities | | |
Available-for-sale marketable securities: | | |
Available-for-sale marketable securities, fair value | 0 | 0 |
Fair Value, Recurring | Level 3 | Yankee bonds | | |
Available-for-sale marketable securities: | | |
Available-for-sale marketable securities, fair value | 0 | 0 |
Fair Value, Recurring | Level 3 | Corporate debt securities | | |
Available-for-sale marketable securities: | | |
Available-for-sale marketable securities, fair value | $ 0 | $ 0 |