> ## Documentation Index
> Fetch the complete documentation index at: https://docs.xbox.com/llms.txt
> Use this file to discover all available pages before exploring further.

# mock (contents)

> mock

## Functions

| Function | Description |
| - | - |
| [HCMockAddMock](https://docs.xbox.com/reference/live/httpclient/mock/functions/hcmockaddmock.md) | Configures libHttpClient to return mock response instead of making a network call when HCHttpCallPerformAsync() is called. |
| [HCMockCallCloseHandle](https://docs.xbox.com/reference/live/httpclient/mock/functions/hcmockcallclosehandle.md) | Closes a mock HTTP call handle. |
| [HCMockCallCreate](https://docs.xbox.com/reference/live/httpclient/mock/functions/hcmockcallcreate.md) | Creates a mock HTTP call handle. |
| [HCMockCallDuplicateHandle](https://docs.xbox.com/reference/live/httpclient/mock/functions/hcmockcallduplicatehandle.md) | Duplicates a mock HTTP call handle. |
| [HCMockClearMocks](https://docs.xbox.com/reference/live/httpclient/mock/functions/hcmockclearmocks.md) | Removes all mocks added by HCMockAddMock. |
| [HCMockRemoveMock](https://docs.xbox.com/reference/live/httpclient/mock/functions/hcmockremovemock.md) | Removes a mock that was added by HCMockAddMock. |
| [HCMockResponseSetHeader](https://docs.xbox.com/reference/live/httpclient/mock/functions/hcmockresponsesetheader.md) | Set a response header to return for the mock. |
| [HCMockResponseSetNetworkErrorCode](https://docs.xbox.com/reference/live/httpclient/mock/functions/hcmockresponsesetnetworkerrorcode.md) | Set the network error code to return for the mock. |
| [HCMockResponseSetResponseBodyBytes](https://docs.xbox.com/reference/live/httpclient/mock/functions/hcmockresponsesetresponsebodybytes.md) | Set the response body string to return for the mock. |
| [HCMockResponseSetStatusCode](https://docs.xbox.com/reference/live/httpclient/mock/functions/hcmockresponsesetstatuscode.md) | Set the HTTP status code to return for the mock. |
| [HCMockSetMockMatchedCallback](https://docs.xbox.com/reference/live/httpclient/mock/functions/hcmocksetmockmatchedcallback.md) | Add an intermediate callback that will be called when the specified mock is matched. This gives the client another opportunity to specify the mock response. |

## Callbacks

| Callback | Description |
| - | - |
| [HCMockMatchedCallback](https://docs.xbox.com/reference/live/httpclient/mock/functions/hcmockmatchedcallback.md) | Callback that's invoked when a mock is matched, before libHttpClient copies the mock response to the call. |


## Related topics

- [HCMockAddMock](https://docs.xbox.com/reference/live/httpclient/mock/functions/hcmockaddmock.md)
- [HCMockClearMocks](https://docs.xbox.com/reference/live/httpclient/mock/functions/hcmockclearmocks.md)
- [HCMockRemoveMock](https://docs.xbox.com/reference/live/httpclient/mock/functions/hcmockremovemock.md)
- [HttpClient API reference (contents)](https://docs.xbox.com/reference/live/httpclient/atoc-httpclient.md)
- [HCMockSetMockMatchedCallback](https://docs.xbox.com/reference/live/httpclient/mock/functions/hcmocksetmockmatchedcallback.md)
