# Schedules

Handles all Security Token Checkpoint Schedules related functionality

## Hierarchy

* Namespace‹[SecurityToken](https://developers.polymath.network/polymesh-sdk-api-reference/docs-v9/classes/securitytoken)›

  ↳ **Schedules**

## Index

### Properties

* [context](#protected-context)
* [parent](#protected-parent)

### Methods

* [complexityOf](#complexityof)
* [create](#create)
* [currentComplexity](#currentcomplexity)
* [get](#get)
* [maxComplexity](#maxcomplexity)
* [remove](#remove)

## Properties

### `Protected` context

• **context**: [*Context*](https://developers.polymath.network/polymesh-sdk-api-reference/docs-v9/classes/context)

*Inherited from void*

*Defined in* [*src/api/entities/Namespace.ts:11*](https://github.com/PolymathNetwork/polymesh-sdk/blob/56921667/src/api/entities/Namespace.ts#L11)

### `Protected` parent

• **parent**: [*SecurityToken*](https://developers.polymath.network/polymesh-sdk-api-reference/docs-v9/classes/securitytoken)

*Inherited from void*

*Defined in* [*src/api/entities/Namespace.ts:9*](https://github.com/PolymathNetwork/polymesh-sdk/blob/56921667/src/api/entities/Namespace.ts#L9)

## Methods

### complexityOf

▸ **complexityOf**(`period`: [CalendarPeriod](https://developers.polymath.network/polymesh-sdk-api-reference/docs-v9/interfaces/calendarperiod)): *number*

*Defined in* [*src/api/entities/SecurityToken/Checkpoints/Schedules.ts:105*](https://github.com/PolymathNetwork/polymesh-sdk/blob/56921667/src/api/entities/SecurityToken/Checkpoints/Schedules.ts#L105)

Calculate an abstract measure of the complexity of a given Calendar Period

**Parameters:**

| Name     | Type                                                                                                               |
| -------- | ------------------------------------------------------------------------------------------------------------------ |
| `period` | [CalendarPeriod](https://developers.polymath.network/polymesh-sdk-api-reference/docs-v9/interfaces/calendarperiod) |

**Returns:** *number*

### create

▸ **create**(`args`: [CreateCheckpointScheduleParams](https://developers.polymath.network/polymesh-sdk-api-reference/docs-v9/interfaces/createcheckpointscheduleparams), `opts?`: [ProcedureOpts](https://developers.polymath.network/polymesh-sdk-api-reference/docs-v9/interfaces/procedureopts)): *Promise‹*[*TransactionQueue*](https://developers.polymath.network/polymesh-sdk-api-reference/docs-v9/classes/transactionqueue)*‹*[*CheckpointSchedule*](https://developers.polymath.network/polymesh-sdk-api-reference/docs-v9/classes/checkpointschedule)*››*

*Defined in* [*src/api/entities/SecurityToken/Checkpoints/Schedules.ts:55*](https://github.com/PolymathNetwork/polymesh-sdk/blob/56921667/src/api/entities/SecurityToken/Checkpoints/Schedules.ts#L55)

Create a schedule for Checkpoint creation (i.e. "Create a checkpoint every week for 5 weeks, starting next tuesday")

**`note`** due to chain limitations, schedules are advanced and (if appropriate) executed whenever the Security Token is redeemed, issued or transferred between portfolios. This means that on a Security Token without much movement, there may be disparities between intended Checkpoint creation dates and the actual date when they are created. This, however, has no effect on the Checkpoint's accuracy regarding to balances

**`note`** this method is of type [ProcedureMethod](https://developers.polymath.network/polymesh-sdk-api-reference/docs-v9/interfaces/proceduremethod), which means you can call `create.checkAuthorization` on it to see whether the Current Account has the required permissions to run it

**Parameters:**

| Name    | Type                                                                                                                                               |
| ------- | -------------------------------------------------------------------------------------------------------------------------------------------------- |
| `args`  | [CreateCheckpointScheduleParams](https://developers.polymath.network/polymesh-sdk-api-reference/docs-v9/interfaces/createcheckpointscheduleparams) |
| `opts?` | [ProcedureOpts](https://developers.polymath.network/polymesh-sdk-api-reference/docs-v9/interfaces/procedureopts)                                   |

**Returns:** *Promise‹*[*TransactionQueue*](https://developers.polymath.network/polymesh-sdk-api-reference/docs-v9/classes/transactionqueue)*‹*[*CheckpointSchedule*](https://developers.polymath.network/polymesh-sdk-api-reference/docs-v9/classes/checkpointschedule)*››*

### currentComplexity

▸ **currentComplexity**(): *Promise‹number›*

*Defined in* [*src/api/entities/SecurityToken/Checkpoints/Schedules.ts:113*](https://github.com/PolymathNetwork/polymesh-sdk/blob/56921667/src/api/entities/SecurityToken/Checkpoints/Schedules.ts#L113)

Calculate the sum of the complexity of all current Checkpoint Schedules for this Security Token. The number cannot exceed the Token's maximum complexity (obtained via [maxComplexity](#maxcomplexity))

**Returns:** *Promise‹number›*

### get

▸ **get**(): *Promise‹*[*ScheduleWithDetails*](https://developers.polymath.network/polymesh-sdk-api-reference/docs-v9/interfaces/schedulewithdetails)*\[]›*

*Defined in* [*src/api/entities/SecurityToken/Checkpoints/Schedules.ts:72*](https://github.com/PolymathNetwork/polymesh-sdk/blob/56921667/src/api/entities/SecurityToken/Checkpoints/Schedules.ts#L72)

Retrieve all active Checkpoint Schedules

**Returns:** *Promise‹*[*ScheduleWithDetails*](https://developers.polymath.network/polymesh-sdk-api-reference/docs-v9/interfaces/schedulewithdetails)*\[]›*

### maxComplexity

▸ **maxComplexity**(): *Promise‹number›*

*Defined in* [*src/api/entities/SecurityToken/Checkpoints/Schedules.ts:122*](https://github.com/PolymathNetwork/polymesh-sdk/blob/56921667/src/api/entities/SecurityToken/Checkpoints/Schedules.ts#L122)

Retrieve the maximum allowed Schedule complexity for this Security Token

**Returns:** *Promise‹number›*

### remove

▸ **remove**(`args`: [RemoveCheckpointScheduleParams](https://developers.polymath.network/polymesh-sdk-api-reference/docs-v9/interfaces/removecheckpointscheduleparams), `opts?`: [ProcedureOpts](https://developers.polymath.network/polymesh-sdk-api-reference/docs-v9/interfaces/procedureopts)): *Promise‹*[*TransactionQueue*](https://developers.polymath.network/polymesh-sdk-api-reference/docs-v9/classes/transactionqueue)*‹void››*

*Defined in* [*src/api/entities/SecurityToken/Checkpoints/Schedules.ts:65*](https://github.com/PolymathNetwork/polymesh-sdk/blob/56921667/src/api/entities/SecurityToken/Checkpoints/Schedules.ts#L65)

Remove the supplied Checkpoint Schedule for a given Security Token

**`note`** this method is of type [ProcedureMethod](https://developers.polymath.network/polymesh-sdk-api-reference/docs-v9/interfaces/proceduremethod), which means you can call `remove.checkAuthorization` on it to see whether the Current Account has the required permissions to run it

**Parameters:**

| Name    | Type                                                                                                                                               |
| ------- | -------------------------------------------------------------------------------------------------------------------------------------------------- |
| `args`  | [RemoveCheckpointScheduleParams](https://developers.polymath.network/polymesh-sdk-api-reference/docs-v9/interfaces/removecheckpointscheduleparams) |
| `opts?` | [ProcedureOpts](https://developers.polymath.network/polymesh-sdk-api-reference/docs-v9/interfaces/procedureopts)                                   |

**Returns:** *Promise‹*[*TransactionQueue*](https://developers.polymath.network/polymesh-sdk-api-reference/docs-v9/classes/transactionqueue)*‹void››*
