---
title: "Create a new AoF consent"
method: POST
path: "/consents/v1/account-on-file"
tags: ["Consents Account On File"]
---

# Create a new AoF consent

`POST /consents/v1/account-on-file`

Creates a new Account-on-File consent that can be authorized later.

## Request body

- object
  - `customer_id` string, uuid, required — The unique identifier of the customer for whom the consent is being created.
  - `destination_account_id` string, uuid, required — The unique identifier of the account acting as a consent beneficiary.
  - `currency` string, required — The ISO 3 letter currency code
  - `reference` string, required — A reason or reference in relation to a payment. Maximum 64 chars
  - `purpose` 'FIS' | 'TCS' | 'MWP' | 'OAT' | 'IFS' | 'RNT' | 'LNC' | 'PIN' | 'GDS', required — A category code that relates to the type of services or goods that corresponds to the underlying purpose of the payment. The code must conform to the payment purpose code list. **Supported values:** - `FIS` – Financial services - `TCS` – Telecommunication services - `MWP` – Mobile wallet card payments - `OAT` – Own account transfer - `IFS` – Information services - `RNT` – Rent payments - `LNC` – Loan charges - `PIN` – Personal investments - `GDS` – Goods bought or sold
  - `control_parameters` ControlParameters, required — Defines the control parameters for a Account On File (AoF) consent. These parameters specify the applicable limits for individual payments, cumulative amounts, and the number of payments allowed within a defined period or across the consent's lifetime. At least one of `max_individual_amount`, `max_cumulative_amount`, or `max_cumulative_number_of_payments` must be provided.
    - `type` string, required — Discriminator type identifying the control parameters variant
    - `period_type` 'Day' | 'Week' | 'Month' | 'Year', required — Defines the time period used for applying limits on a long‑lived consent. This value determines how consumption limits (e.g., maximum amounts or number of payments) are calculated within each period. **Supported values:** - `Day` – A single calendar day (00:00 to 23:59). - `Week` – Seven consecutive days. - `Month` – A full calendar month (from the 1st to the last day). - `Year` – A full calendar year (12 consecutive months).
    - `max_individual_amount` number — Maximum amount allowed for a single payment
    - `max_cumulative_amount` number — Maximum cumulative amount allowed across all payments
    - `max_cumulative_number_of_payments` integer — Maximum number of payments allowed in total
    - `max_cumulative_amount_per_period` number — Maximum cumulative amount allowed per period
    - `max_cumulative_number_of_payments_per_period` integer — Maximum number of payments allowed per period
  - `government_identifier` GovernmentIdentifierRequest
    - `value` string, required — The identifier value
    - `type` 'EMIRATES_ID' | 'TRADE_LICENSE_NUMBER', required — The type of Government ID
  - `start_date_time` string, date-time, nullable — The date and time when the consent becomes active. **Optional.** Defaults to the current date and time if not provided.
  - `expiration_date_time` string, date-time, nullable — The date and time when the consent expires. **Optional.** Defaults to one year after `start_date_time` if not provided.
  - `immediate_payment` ImmediatePayment, nullable — Details of a payment that will be executed immediately after the user successfully authorizes the consent. If present, the payment is initiated automatically as part of the consent authorization flow.
    - `amount` number, required — The amount to be paid immediately upon consent authorization
    - `reference` string — A reason or reference in relation to a payment. Maximum 64 chars
    - `creditor_reference` string, nullable — Clients identifier that can be used in their ERP systems

## Response `200`

Consent created successfully

- CreateAccountOnFileResponse
  - `id` string, uuid, required — The unique identifier for the consent. Provided as a UUID.
  - `application_id` string, required — Application identifier owning this consent
  - `start_date_time` string, date-time, required — Date and time from when the consent will be active
  - `expiration_date_time` string, date-time, required — Date and time of the expiration of this consent
  - `customer_id` string, uuid, required — Id of a customer that this consent belongs to
  - `status` 'AWAITING_AUTHORISATION' | 'AUTHORISED' | 'REVOKED' | 'REJECTED' | 'EXPIRED' | 'CONSUMED' | 'SUSPENDED', required — Current status of this consent.
  - `destination_account_id` string, uuid, required — Account id that this consent allows payments to
  - `reference` string, required — A reason or reference in relation to a payment. Passed as a part of OF `creditor_reference`. This value will be used as default reference for payments made with this consent.
  - `currency` string, required — The ISO 3 letter currency code
  - `purpose` 'FIS' | 'TCS' | 'MWP' | 'OAT' | 'IFS' | 'RNT' | 'LNC' | 'PIN' | 'GDS', required — A category code that relates to the type of services or goods that corresponds to the underlying purpose of the payment. The code must conform to the payment purpose code list. **Supported values:** - `FIS` – Financial services - `TCS` – Telecommunication services - `MWP` – Mobile wallet card payments - `OAT` – Own account transfer - `IFS` – Information services - `RNT` – Rent payments - `LNC` – Loan charges - `PIN` – Personal investments - `GDS` – Goods bought or sold
  - `control_parameters` ControlParameters, required — Defines the control parameters for a Account On File (AoF) consent. These parameters specify the applicable limits for individual payments, cumulative amounts, and the number of payments allowed within a defined period or across the consent's lifetime. At least one of `max_individual_amount`, `max_cumulative_amount`, or `max_cumulative_number_of_payments` must be provided.
    - `type` string, required — Discriminator type identifying the control parameters variant
    - `period_type` 'Day' | 'Week' | 'Month' | 'Year', required — Defines the time period used for applying limits on a long‑lived consent. This value determines how consumption limits (e.g., maximum amounts or number of payments) are calculated within each period. **Supported values:** - `Day` – A single calendar day (00:00 to 23:59). - `Week` – Seven consecutive days. - `Month` – A full calendar month (from the 1st to the last day). - `Year` – A full calendar year (12 consecutive months).
    - `max_individual_amount` number — Maximum amount allowed for a single payment
    - `max_cumulative_amount` number — Maximum cumulative amount allowed across all payments
    - `max_cumulative_number_of_payments` integer — Maximum number of payments allowed in total
    - `max_cumulative_amount_per_period` number — Maximum cumulative amount allowed per period
    - `max_cumulative_number_of_payments_per_period` integer — Maximum number of payments allowed per period
  - `immediate_payment` ImmediatePayment, nullable — Details of a payment that will be executed immediately after the user successfully authorizes the consent. If present, the payment is initiated automatically as part of the consent authorization flow.
    - `amount` number, required — The amount to be paid immediately upon consent authorization
    - `reference` string — A reason or reference in relation to a payment. Maximum 64 chars
    - `creditor_reference` string, nullable — Clients identifier that can be used in their ERP systems

---

[API](https://skmtc.net/leantech/apis/auth.md) · [All operations](https://skmtc.net/leantech/apis/auth/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/leantech/auth/revisions/c2e46d54d886/schema)
