

本文為英文版的機器翻譯版本，如內容有任何歧義或不一致之處，概以英文版為準。

# 將來源識別碼新增至 Amazon RDS 事件通知訂閱
<a name="USER_Events.AddingSource"></a>

您可以將來源識別碼 (產生事件的 Amazon RDS 來源) 新增至現有的訂閱。

## 主控台
<a name="USER_Events.AddingSource.Console"></a>

您可以在修改訂閱時，使用 Amazon RDS 主控台選取或取消選取來源識別碼，以輕鬆地新增或移除來源識別碼。如需更多詳細資訊，請參閱 [修改 Amazon RDS 事件通知訂閱](USER_Events.Modifying.md)。

## AWS CLI
<a name="USER_Events.AddingSource.CLI"></a>

若要將來源識別符新增至 Amazon RDS 事件通知訂閱，請使用 AWS CLI [https://docs.aws.amazon.com/](https://docs.aws.amazon.com/)命令。包含下列必要參數：
+ `--subscription-name`
+ `--source-identifier`

**Example**  
下列範例將來源識別碼 `mysqldb` 新增至 `myrdseventsubscription` 訂閱。  
對於 Linux、macOS 或 Unix：  

```
aws rds add-source-identifier-to-subscription \
    --subscription-name myrdseventsubscription \
    --source-identifier mysqldb
```
在 Windows 中：  

```
aws rds add-source-identifier-to-subscription ^
    --subscription-name myrdseventsubscription ^
    --source-identifier mysqldb
```

## API
<a name="USER_Events.AddingSource.API"></a>

呼叫 Amazon RDS API [https://docs.aws.amazon.com/AmazonRDS/latest/APIReference/API_AddSourceIdentifierToSubscription.html](https://docs.aws.amazon.com/AmazonRDS/latest/APIReference/API_AddSourceIdentifierToSubscription.html) 將來源識別碼新增至 Amazon RDS 事件通知訂閱。包含下列必要參數：
+ `SubscriptionName`
+ `SourceIdentifier`