# Create DCA Plan

`POST` `/v1/dailycoins/create`

:::warning Longbridge HK / SG accounts only
This method is available to Longbridge HK / SG accounts only. It works with any supported symbol, including US stocks.
:::

Create a new recurring investment plan for a security.

## Parameters

### Request Body

| Name | Type | Required | Description |
| --- | --- | --- | --- |
| `symbol` | string | Yes | Security symbol, e.g. `AAPL.US`. |
| `per_invest_amount` | string | Yes | Recurring investment amount per execution. |
| `invest_frequency` | string | Yes | Frequency: `Daily`, `Weekly`, `Fortnightly`, `Monthly`. |
| `allow_margin_finance` | integer | Yes | Whether to allow margin financing: `1` yes, `0` no. |
| `invest_day_of_week` | string | No | Day of week for weekly/fortnightly plans: `mon`–`fri`. |
| `invest_day_of_month` | string | No | Day of month for monthly plans: `1`–`28`. |

## Request Example

```bash
curl --request POST \
  --url 'https://openapi.longbridge.com/v1/dailycoins/create' \
  --header 'Authorization: Bearer <access_token>' \
  --header 'Content-Type: application/json' \
  --data '{"symbol":"<symbol>","per_invest_amount":"<per_invest_amount>","invest_frequency":"<invest_frequency>","allow_margin_finance":0,"invest_day_of_week":"<invest_day_of_week>","invest_day_of_month":"<invest_day_of_month>"}'
```

## Response

### Response Properties

| Name | Type | Required | Description |
| --- | --- | --- | --- |
| `id` | string | Yes | ID of the newly created plan |

### Response JSON Example

```json
{
  "code": 0,
  "message": "success",
  "data": {
    "id": "1225781523156889601"
  }
}
```
