# Programs
> Programs determine the compliance and commercial terms of Accounts. By default, you have a Commercial Banking program for managing your own funds. If you are lending or managing funds on behalf of your customers, or otherwise engaged in regulated activity, we will work together to create additional Programs for you.

[Events](https://increase.com/documentation/events.md) will be generated for this resource. The possible event categories are: `program.created` and `program.updated`.

## The Program object
### Example
```json
{
  "bank": "first_internet_bank",
  "billing_account_id": null,
  "created_at": "2020-01-31T23:59:59Z",
  "default_digital_card_profile_id": null,
  "id": "program_i2v2os4mwza1oetokh9i",
  "interest_rate": "0.01",
  "lending": null,
  "name": "Commercial Banking",
  "type": "program",
  "updated_at": "2020-01-31T23:59:59Z"
}
```
### Attributes
- `bank` (enum)
  The Bank the Program is with.
  Cases:
  * `core_bank` (Core Bank)
  * `first_internet_bank` (First Internet Bank of Indiana)
  * `grasshopper_bank` (Grasshopper Bank)

- `billing_account_id` (string, nullable)
  The Program billing account.

- `created_at` (string)
  The [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) time at which the Program was created.

- `default_digital_card_profile_id` (string, nullable)
  The default configuration for digital cards attached to this Program.

- `id` (string)
  The Program identifier.

- `interest_rate` (string)
  The Interest Rate currently being earned on the accounts in this program, as a string containing a decimal number. For example, a 1% interest rate would be represented as "0.01".

- `lending` (dictionary, nullable)
  The lending details for the program.

  - `lending.maximum_extendable_credit` (integer)
    The maximum extendable credit of the program.

- `name` (string)
  The name of the Program.

- `type` (string)
  A constant representing the object's type. For this resource it will always be `program`.

- `updated_at` (string)
  The [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) time at which the Program was last updated.

## List Programs
GET /programs

### Example
```curl
curl \
  --url "${INCREASE_URL}/programs" \
  -H "Authorization: Bearer ${INCREASE_API_KEY}"
```

### Query Parameters
- `cursor` (string, optional)
  Return the page of entries after this one.

- `limit` (integer, optional)
  Limit the size of the list that is returned. The default (and maximum) is 100 objects.

### Returns a Program List object:
```json
{
  "data": [
    {
      "bank": "first_internet_bank",
      "billing_account_id": null,
      "created_at": "2020-01-31T23:59:59Z",
      "default_digital_card_profile_id": null,
      "id": "program_i2v2os4mwza1oetokh9i",
      "interest_rate": "0.01",
      "lending": null,
      "name": "Commercial Banking",
      "type": "program",
      "updated_at": "2020-01-31T23:59:59Z"
    }
  ],
  "next_cursor": "v57w5d"
}
```

## Retrieve a Program
GET /programs/{program_id}

### Example
```curl
curl \
  --url "${INCREASE_URL}/programs/program_i2v2os4mwza1oetokh9i" \
  -H "Authorization: Bearer ${INCREASE_API_KEY}"
```
### Path Parameters
- `program_id` (string, required)
  The identifier of the Program to retrieve.

## Sandbox: Create a Program
POST /simulations/programs
> Simulates a [Program](#programs) being created in your group. By default, your group has one program called Commercial Banking. Note that when your group operates more than one program, `program_id` is a required field when creating accounts.
### Example
```curl
curl -X "POST" \
  --url "${INCREASE_URL}/simulations/programs" \
  -H "Authorization: Bearer ${INCREASE_API_KEY}" \
  -H "Content-Type: application/json" \
  -d $'{
    "name": "For Benefit Of"
  }'
```

### Body Parameters
- `bank` (enum, optional)
  The bank for the program's accounts, defaults to First Internet Bank.
  Cases:
  * `core_bank` (Core Bank)
  * `first_internet_bank` (First Internet Bank of Indiana)
  * `grasshopper_bank` (Grasshopper Bank)
  * `twin_city_bank` (Twin City Bank)

- `lending_maximum_extendable_credit` (integer, optional)
  The maximum extendable credit of the program being added.

- `name` (string, required)
  The name of the program being added.

- `reserve_account_id` (string, optional)
  The identifier of the Account the Program should be added to is for.