---
title: "Create link"
method: POST
path: "/v1/recurring-charge-plans/{recurring_charge_plan_id}/accounts/{account_id}"
tags: ["Recurring charge links"]
---

# Create link

`POST /v1/recurring-charge-plans/{recurring_charge_plan_id}/accounts/{account_id}`

## Request

- Base URL: `https://sandbox.pismolabs.io/recurring-charge`
- URL: `https://sandbox.pismolabs.io/recurring-charge/v1/recurring-charge-plans/{recurring_charge_plan_id}/accounts/{account_id}`
- Auth: HTTP bearer

Creates a link between an active recurring charge plan and an account.

This endpoint generates a [Recurring charge plan linked to account](https://developers.pismo.io/events/docs/balance-recurring-charge-plan-linked-to-account-1) event.

**NOTE:** This endpoint requires an account token — an access token encoded with an account ID. Tokens can expire quickly, which can result in a **401 Unauthorized** message.

## Path parameters

- `recurring_charge_plan_id` integer, required
- `account_id` integer, required

## Headers

- `x-cid` string

## Request body

- object
  - `description` string: A description of the scheduled charge that's linked to the account. Use `counter` to specify where the cycle count should be placed. Example: "Annuity {counter}" generates "Annuity 2/12" for the second of twelve annutities. If `counter` is not present, the counter is placed at the end of the description. If no description is configured, the description of the transaction type is used, and the counter is not shown.
  - `tracking_id` string, required: Tracking ID
  - `post_installment_charge_on_current_cycle` boolean: When it's true, the charge will be apply on the current cycle otherwise, it will be apply on the next cycle
  - `start_installment_charge_in` integer: Indicates when to start applying the charge. For example, if start_installment_charge_in is 3, then the charge is applied starting with cycle 3. It's not applied to cycles 1 and 2. If post_installment_charge_on_current_cycle is true, start_installment_charge_in should be null. If post_installment_charge_on_current_cycle is false, start_installment_charge_in is required. In this case, it must be greater than or equal to the current cycle and less than or equal to number_of_cycles.
  - `renew` boolean: When it's true the migration has a renovation

## Response `200`

OK - Indicates that the server accepted the request and created the link.

- LinkCreationResponseDto: Represents the link between a plan and an account.
  - `recurring_charge_link_id` integer: ID of recurring charge link
  - `account_id` integer: Account ID
  - `recurring_charge_plan_id` integer: ID of recurring charge plan
  - `org_id` string: Organization ID
  - `created_at` string: Date/time (GMT-3) that asset was registered on Pismo platform
  - `description` string: A description of the scheduled charge that's linked to the account. Use `counter` to specify where the cycle count should be placed. Example: "Annuity {counter}" generates "Annuity 2/12" for the second of twelve annutities. If `counter` is not present, the counter is placed at the end of the description. If no description is configured, the description of the transaction type is used, and the counter is not shown.
  - `tracking_id` string: Tracking ID
  - `creation_cid` string: CID for the creation event
  - `post_installment_charge_on_current_cycle` boolean: When it's true, the charge will be apply on the current cycle otherwise, it will be apply on the next cycle
  - `start_installment_charge_in` integer: Indicates when to start applying the charge. For example, if start_installment_charge_in is 3, then the charge is applied starting with cycle 3. It's not applied to cycles 1 and 2. If post_installment_charge_on_current_cycle is true, start_installment_charge_in should be null. If post_installment_charge_on_current_cycle is false, start_installment_charge_in is required. In this case, it must be greater than or equal to the current cycle and less than or equal to number_of_cycles.
  - `renew` boolean: When it's true the migration has a renovation

## Other responses

- `400`: Bad Request
- `404`: Not Found
- `500`: Internal server error

---

[API](https://skmtc.dev/pismo/apis/revolving-credit-recurring-charges.md) - [All operations](https://skmtc.dev/pismo/apis/revolving-credit-recurring-charges/llms.txt) - [OpenAPI document](https://skmtc.dev/pismo/apis/revolving-credit-recurring-charges/revisions/a5fea1d82e51?raw)
