> For the complete documentation index, see [llms.txt](https://docs-v2.hypertest.co/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs-v2.hypertest.co/user-guides/node.js-sdk/discard-a-test-case-request-while-recording.md).

# Discard a test case(Request) while recording

For any reason if you want to avoid recording a request at run time you can use "discardRequest" API exposed by HyperTest SDK.

```typescript
app.get('/api/getProducts', async (req: Request, res: Response) => {
    const data = await getProducts();
    htSdk.discardRequest(); // discard recorded test case of the current request
    res.send(data);
});
```
