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

# HCHttpCallResponseSetHeader

> HCHttpCallResponseSetHeader

# HCHttpCallResponseSetHeader

为 HTTP 调用设置响应标头。

## Syntax

```cpp theme={null}
HRESULT HCHttpCallResponseSetHeader(  
         HCCallHandle call,  
         const char* headerName,  
         const char* headerValue  
)  
```

### Parameters

*call*   \_In\_\
Type: HCCallHandle

HTTP 调用的句柄。

*headerName*   \_In\_z\_\
Type: char\*

HTTP 调用的 UTF-8 编码响应标头名称。

*headerValue*   \_In\_z\_\
Type: char\*

HTTP 调用的 UTF-8 编码响应标头值。

### Return value

Type: HRESULT

此 API 操作的结果代码。可能的值为 S\_OK、E\_INVALIDARG、E\_OUTOFMEMORY 或 E\_FAIL。

## Requirements

**Header:** httpProvider.h

**Library:** libHttpClient.GDK.lib

## See also

[httpProvider](/reference/live/httpclient/httpprovider/httpprovider_members)
