> For the complete documentation index, see [llms.txt](https://smallso.gitbook.io/tencent-cloud-sdk/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://smallso.gitbook.io/tencent-cloud-sdk/python-docs/serverless-functions/class-and-method/function-code.md).

# FunctionCode 类

## 简要

代表无服务器云函数源代码配置的类。通过利用该类，您可以快速指定无服务器云函数的源代码，而无需关注源代码数据类型。

```python
class FunctionCode
```

## 构造

该类仅支持构造类实例后使用，其构造实例方法签名如下：

```python
def __init__(self)
```

## 示例

在下文中我们将向您演示如何构造一个无服务器云函数源代码类实例并使用它。

```python
from tencent.cloud.serverless import functions

# The method will return itself.

functions.FunctionCode().use_object_storage_bucket(
    region_id = 'ap-shanghai-1',
    bucket_name = 'scf-code',
    object_name = 'source.zip'
)
```

## 适用于

#### Tencent Cloud SDK for Python

产品软件包：tencent-cloud-sdk-serverless-functions >= 0.1.1
