Citi Consent Management API

API services to create, retrieve, and delete account information consent.

Operations 3

POST /account-consent accountInformationConsent #
GET /account-consent/{consentId} accountInformationConsentInquiry #
DELETE /account-consent/{consentId} accountInformationConsentDeletion #

Documentation

📖
Documentation
https://developer.citi.com/apidocs/authentication/authentication-only-guide
📖
APIReference
https://developer.citi.com/apidocs/authentication/authentication-api-reference
📖
Authentication
https://raw.githubusercontent.com/api-evangelist/citi/refs/heads/main/authentication/citi-authentication.yml
📖
Documentation
https://developer.citi.com/apidocs/account-reporting/balances/balances-overview
📖
APIReference
https://developer.citi.com/apidocs/account-reporting/balances/balances-api-reference
📖
Documentation
https://developer.citi.com/apidocs/outgoing-payments/payments/payments-overview
📖
APIReference
https://developer.citi.com/apidocs/outgoing-payments/payments/payments-api-reference
📖
Documentation
https://developer.citi.com/apidocs/accept-payments/online-payment-acceptance/online-payment-acceptance-overview
📖
APIReference
https://developer.citi.com/apidocs/accept-payments/online-payment-acceptance/online-payment-acceptance-api-reference
📖
Documentation
https://developer.citi.com/apidocs/commercial-cards/virtual-cards/commercial-cards-overview
📖
APIReference
https://developer.citi.com/apidocs/commercial-cards/virtual-cards/virtual-cards-api-reference
📖
Documentation
https://developer.citi.com/apidocs/fx/gateway/citifx-gateway-overview
📖
APIReference
https://developer.citi.com/apidocs/fx/instant-fx/instant-fx-overview
📖
Documentation
https://developer.citi.com/apidocs/custody/accounts/accounts-overview
📖
APIReference
https://developer.citi.com/apidocs/custody/safekeeping-positions/safekeeping-positions-api-reference
📖
Documentation
https://developer.citi.com/apidocs/transfer-agency/accounts/accounts-overview
📖
APIReference
https://developer.citi.com/apidocs/transfer-agency/accounts/accounts-api-reference
📖
Documentation
https://developer.citi.com/apidocs/open-banking/ukraine-open-banking/ukraine-open-banking-overview
📖
APIReference
https://developer.citi.com/apidocs/open-banking/ukraine-open-banking/ukraine-bank-data-sharing-api-reference
📖
Documentation
https://developer.citi.com/apidocs/trade/standby-letters-of-credit/trade-overview
📖
APIReference
https://developer.citi.com/apidocs/trade/standby-letters-of-credit/trade-api-reference
📖
Documentation
https://developer.citi.com/apidocs/gateway-services/gateway-services-user-guide
📖
APIReference
https://developer.citi.com/apidocs/gateway-services/gateway-services-api-reference
📖
Documentation
https://developer.citi.com/apidocs/additional-payment-services/additional-payment-services/additional-payment-services-overview
📖
APIReference
https://developer.citi.com/apidocs/additional-payment-services/additional-payment-services/additional-payment-services-api-reference

Specifications

Other Resources

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/citi-consent-management-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

citi-consent-management-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: Bank Data Sharing Consent Management API
  version: 1.0.0
  description: Manage account consent and access real-time account details, balances, and transactions through our secure open banking API.
  contact:
    name: Citi API Support
servers:
- url: https://b2b.tts.icgservices.citi.com/citiconnect/openbanking/ukr/accountconsentservices/v1
  description: production gateway url
- url: https://sanbox.tts.icgservices.citi.com/citiconnect/openbanking/ukr/accountconsentservices/v1
  description: sbox url
security:
- oAuth:
  - authenticationservices/v1
tags:
- name: Consent Management
  description: API services to create, retrieve, and delete account information consent.
paths:
  /account-consent:
    post:
      tags:
      - Consent Management
      summary: accountInformationConsent
      description: Create an account information consent resource that captures permission scope, participant details, and authentication context, enabling subsequent authorized account and balance data access requests by the approved TPP.
      servers:
      - url: https://b2b.tts.icgservices.citi.com/citiconnect/openbanking/ukr/accountconsentservices/v1
      operationId: accountInformationConsent
      parameters:
      - $ref: '#/components/parameters/Request-ID'
      - $ref: '#/components/parameters/Group-ID'
      - $ref: '#/components/parameters/TPP-Code'
      - $ref: '#/components/parameters/PSU-IP-Address'
      - $ref: '#/components/parameters/Date'
      requestBody:
        description: Account information consent payload containing participant, SCA, and permission details.
        required: false
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/AccountInformationConsentRequest'
            examples:
              Consent-Create-Request:
                $ref: '#/components/examples/Consent-Create-Request'
      responses:
        '201':
          description: Account Information Consent Response.
          headers:
            Request-ID:
              $ref: '#/components/headers/Request-ID'
            Group-ID:
              $ref: '#/components/headers/Group-ID'
            TPP-Code:
              $ref: '#/components/headers/TPP-Code'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/AccountInformationConsent'
              examples:
                Consent-Create-Response:
                  $ref: '#/components/examples/Consent-Create-Response'
        '400':
          $ref: '#/components/responses/Bad-Request'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          $ref: '#/components/responses/Forbidden'
        '404':
          $ref: '#/components/responses/Not-Found'
        '405':
          $ref: '#/components/responses/Method-Not-Allowed'
        '409':
          $ref: '#/components/responses/Conflict'
        '415':
          $ref: '#/components/responses/Unsupported-Media-Type'
        '429':
          $ref: '#/components/responses/Too-Many-Requests'
        '500':
          $ref: '#/components/responses/Internal-Server-Error'
        '503':
          $ref: '#/components/responses/Service-Unavailable'
        '504':
          $ref: '#/components/responses/Gateway-Timeout'
      security:
      - oAuth:
        - authenticationservices/v1
  /account-consent/{consentId}:
    get:
      tags:
      - Consent Management
      summary: accountInformationConsentInquiry
      description: Retrieve the current status and full details of an existing account information consent using the provided `consentId`, so clients can verify validity, permissions, and lifecycle state before data access.
      servers:
      - url: https://b2b.tts.icgservices.citi.com/citiconnect/openbanking/ukr/accountconsentservices/v1
      operationId: accountInformationConsentInquiry
      parameters:
      - $ref: '#/components/parameters/Consent-Id-Path'
      - $ref: '#/components/parameters/Request-ID'
      - $ref: '#/components/parameters/Group-ID'
      - $ref: '#/components/parameters/TPP-Code'
      - $ref: '#/components/parameters/PSU-IP-Address'
      - $ref: '#/components/parameters/Date'
      responses:
        '200':
          $ref: '#/components/responses/Account-Consent-Inquiry'
        '400':
          $ref: '#/components/responses/Bad-Request'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          $ref: '#/components/responses/Forbidden'
        '404':
          $ref: '#/components/responses/Not-Found'
        '405':
          $ref: '#/components/responses/Method-Not-Allowed'
        '409':
          $ref: '#/components/responses/Conflict'
        '415':
          $ref: '#/components/responses/Unsupported-Media-Type'
        '429':
          $ref: '#/components/responses/Too-Many-Requests'
        '500':
          $ref: '#/components/responses/Internal-Server-Error'
        '503':
          $ref: '#/components/responses/Service-Unavailable'
        '504':
          $ref: '#/components/responses/Gateway-Timeout'
      security:
      - oAuth:
        - authenticationservices/v1
    delete:
      tags:
      - Consent Management
      summary: accountInformationConsentDeletion
      description: Revoke and delete an existing account information consent identified by `consentId`, preventing further use of that consent for account data retrieval and ensuring consent lifecycle closure for compliance requirements.
      servers:
      - url: https://b2b.tts.icgservices.citi.com/citiconnect/openbanking/ukr/accountconsentservices/v1
      operationId: accountInformationConsentDeletion
      parameters:
      - $ref: '#/components/parameters/Consent-Id-Path'
      - $ref: '#/components/parameters/Request-ID'
      - $ref: '#/components/parameters/Group-ID'
      - $ref: '#/components/parameters/TPP-Code'
      - $ref: '#/components/parameters/PSU-IP-Address'
      - $ref: '#/components/parameters/Date'
      responses:
        '204':
          $ref: '#/components/responses/No-Content'
        '400':
          $ref: '#/components/responses/Bad-Request'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          $ref: '#/components/responses/Forbidden'
        '404':
          $ref: '#/components/responses/Not-Found'
        '405':
          $ref: '#/components/responses/Method-Not-Allowed'
        '409':
          $ref: '#/components/responses/Conflict'
        '415':
          $ref: '#/components/responses/Unsupported-Media-Type'
        '429':
          $ref: '#/components/responses/Too-Many-Requests'
        '500':
          $ref: '#/components/responses/Internal-Server-Error'
        '503':
          $ref: '#/components/responses/Service-Unavailable'
        '504':
          $ref: '#/components/responses/Gateway-Timeout'
      security:
      - oAuth:
        - authenticationservices/v1
components:
  examples:
    Un-Supported-Media-Type-Service-Error-Example:
      value:
        ref_id: ec689822-9864-4c4d-9d68-222467627902
        error_details:
        - issue: Media type not supported
          action: please use valid content-type in header
          code: CC00002
    Consent-Inquiry-Response:
      value:
        consentInfo:
          consentId: e785e48e345f4e91a1d611f4b65c521a
          creationTime: '2024-03-17T10:30:00Z'
          updateTime: '2024-03-17T10:30:00Z'
          consentStatus: AWAIT_AUTHORIZATION
        sca:
          tppRedirectUrl: https://example.com/callback
        accountInfo:
          permissionInfo:
            permissionType:
            - BASIC_ACCOUNT_INFORMATION
            - BALANCE_INFORMATION
            accessPermissionEndDate: '2024-03-17T10:30:00Z'
    Bad-Request-Example-Account-Ref:
      value:
        ref_id: 344d0f3f-4x55-7g99-8b2c-0cf2a921a5ac
        error_details:
        - code: VC00012
          issue: The account reference number is invalid
          action: Please provide a valid value and retry.
    Unauthorized-Service-Error-Example:
      value:
        ref_id: ec689822-9864-4c4d-9d68-222467627902
        error_details:
        - issue: User not authorized for this functionality
          action: please use valid credentials to access this functionality
          code: CC00007
    Internal-Server-Service-Error-Example:
      value:
        ref_id: ec689822-9864-4c4d-9d68-222467627902
        error_details:
        - issue: unable to serve your request at this moment
          action: Please refer to documentation provided or contact support team
          code: CC00004
    Not-Found-Gateway-Error-Example:
      value:
        httpCode: '404'
        httpMessage: Not Found
        moreInformation: No resources match requested URI
    Bad-Request-Gateway-Error-Example:
      value:
        httpCode: '400'
        httpMessage: Bad Request
        moreInformation: please provide valid value for request
    Too-Many-Requests-Gateway-Example:
      value:
        httpCode: '429'
        httpMessage: Too Many Requests
        moreInformation: Rate Limit exceeded
    Method-Not-Allowed-Service-Error-Example:
      value:
        ref_id: ec689822-9864-4c4d-9d68-222467627901
        error_details:
        - issue: Method not supported
          action: Method not supported for this endpoint, please use valid http verb
          code: CC00001
    Idempotency-Id-Conflict-Example:
      value:
        ref_id: ec689822-9864-4c4d-9d68-222467627902
        error_details:
        - issue: Idempotency-Id provided is currently being used in another request
          action: please do not repeat the same request again
    Bad-Request-Example-Limit:
      value:
        ref_id: 344d0f3f-4x55-7g99-8b2c-0cf2a921a5ac
        error_details:
        - code: VC00012
          issue: provided value is not within the range for query-param limit.
          action: please provide valid value for query-param limit, must be greater than or equal to 1.
    Consent-Create-Response:
      value:
        consentInfo:
          consentId: e785e48e345f4e91a1d611f4b65c521a
          creationTime: '2024-03-17T10:30:00Z'
          updateTime: '2024-03-17T10:30:00Z'
          consentStatus: AWAIT_AUTHORIZATION
        sca:
          tppRedirectUrl: https://example.com/callback
          aspspRedAdr: https://aspsp.example.com/consents/e785e48e345f4e91a1d611f4b65c521a
        accountInfo:
          permissionInfo:
            permissionType:
            - BASIC_ACCOUNT_INFORMATION
            - BALANCE_INFORMATION
            accessPermissionEndDate: '2024-03-17T10:30:00Z'
    Bad-Request-Example:
      value:
        ref_id: 444d0f3f-4x55-7g99-8b2c-0cf2a921a5ab
        error_details:
        - code: VC00012
          issue: The provided value is not within the range for header_account.branch_code parameter
          action: Please provide a valid value for the header_account.branch_code parameter, size must be between 3 and 4.
    Gateway-Timeout-Example:
      value:
        httpCode: '504'
        httpMessage: Gateway Timeout
        moreInformation: 'Response took longer than timeout: PTxxS'
    Bad-Request-Example-From-Date:
      value:
        ref_id: 344d0f3f-4x55-7g99-8b2c-0cf2a921a5ac
        error_details:
        - code: VC00012
          issue: Balance date(s) out of range
          action: From date or To date should not be greater than 180 days from current date.
    Service-Unavailable-Gateway-Example:
      value:
        httpCode: '503'
        httpMessage: Service is temporarily unavailable
        moreInformation: Retry the request after some time
    Forbidden-Service-Example:
      value:
        ref_id: ec689822-9864-4c4d-9d68-222467627902
        error_details:
        - code: CC00008
          issue: User does not have privilege to access this functionality.
          action: Please reach out to support team to enable this feature.
    Un-Supported-Media-Type-Gateway-Error-Example:
      value:
        httpCode: '415'
        httpMessage: Unsupported Media Type
        moreInformation: Unsupported Content-Type application/octet-stream
    Consent-Create-Request:
      value:
        sca:
          tppRedirectUrl: https://example.com/callback
        accountInfo:
          permissionInfo:
            permissionType:
            - BASIC_ACCOUNT_INFORMATION
            - BALANCE_INFORMATION
            accessPermissionEndDate: '2024-03-17T10:30:00Z'
    Unauthorized-Gateway-Error-Example:
      value:
        httpCode: '401'
        httpMessage: Unauthorized
        moreInformation: The server could not verify that you are authorized to access the URL
    Method-Not-Allowed-Gateway-Error-Example:
      value:
        httpCode: '405'
        httpMessage: Method Not Allowed
        moreInformation: The method is not allowed for the requested URL
    Internal-Server-Gateway-Error-Example:
      value:
        httpCode: '500'
        httpMessage: Internal Server Error
        moreInformation: Internal Server Error
  responses:
    Gateway-Timeout:
      description: Gateway Timeout
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Gateway-Error-Response'
          examples:
            Gateway-Timeout-Example:
              $ref: '#/components/examples/Gateway-Timeout-Example'
    Bad-Request:
      description: Bad Request
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Common-Error-Response'
          examples:
            Bad-Request-Example:
              $ref: '#/components/examples/Bad-Request-Example'
            Bad-Request-Example-From-Date:
              $ref: '#/components/examples/Bad-Request-Example-From-Date'
            Bad-Request-Example-Account-Ref:
              $ref: '#/components/examples/Bad-Request-Example-Account-Ref'
            Bad-Request-Example-Limit:
              $ref: '#/components/examples/Bad-Request-Example-Limit'
            Bad-Request-Gateway-Error-Example:
              $ref: '#/components/examples/Bad-Request-Gateway-Error-Example'
    Too-Many-Requests:
      description: Too Many Requests - Rate limit exceeded. Retry after the specified time.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Gateway-Error-Response'
          examples:
            Too-Many-Requests-Gateway-Example:
              $ref: '#/components/examples/Too-Many-Requests-Gateway-Example'
    Unauthorized:
      description: Unauthorized
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Common-Error-Response'
          examples:
            Unauthorized-Service-Error-Example:
              $ref: '#/components/examples/Unauthorized-Service-Error-Example'
            Unauthorized-Gateway-Error-Example:
              $ref: '#/components/examples/Unauthorized-Gateway-Error-Example'
    Not-Found:
      description: Not Found
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Gateway-Error-Response'
          examples:
            Not-Found-Gateway-Error-Example:
              $ref: '#/components/examples/Not-Found-Gateway-Error-Example'
    Conflict:
      description: Conflict
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Service-Error-Response'
          examples:
            Idempotency-Id-Conflict-Example:
              $ref: '#/components/examples/Idempotency-Id-Conflict-Example'
    Account-Consent-Inquiry:
      description: Account Information Consent Response.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/GetAccountInformationConsent'
          examples:
            Consent-Inquiry-Response:
              $ref: '#/components/examples/Consent-Inquiry-Response'
    Method-Not-Allowed:
      description: Method Not Allowed
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Common-Error-Response'
          examples:
            Method-Not-Allowed-Gateway-Error-Example:
              $ref: '#/components/examples/Method-Not-Allowed-Gateway-Error-Example'
            Method-Not-Allowed-Service-Error-Example:
              $ref: '#/components/examples/Method-Not-Allowed-Service-Error-Example'
    Unsupported-Media-Type:
      description: Unsupported Media Type
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Common-Error-Response'
          examples:
            Un-Supported-Media-Type-Gateway-Error-Example:
              $ref: '#/components/examples/Un-Supported-Media-Type-Gateway-Error-Example'
            Un-Supported-Media-Type-Service-Error-Example:
              $ref: '#/components/examples/Un-Supported-Media-Type-Service-Error-Example'
    No-Content:
      description: No Content.
    Internal-Server-Error:
      description: Internal Server Error
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Common-Error-Response'
          examples:
            Internal-Server-Service-Error-Example:
              $ref: '#/components/examples/Internal-Server-Service-Error-Example'
            Internal-Server-Gateway-Error-Example:
              $ref: '#/components/examples/Internal-Server-Gateway-Error-Example'
    Forbidden:
      description: Forbidden
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Service-Error-Response'
          examples:
            Forbidden-Service-Example:
              $ref: '#/components/examples/Forbidden-Service-Example'
    Service-Unavailable:
      description: Service Unavailable - The server is temporarily unable to  handle the request.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Gateway-Error-Response'
          examples:
            Service-Unavailable-Gateway-Example:
              $ref: '#/components/examples/Service-Unavailable-Gateway-Example'
  schemas:
    ScaResponse:
      title: Sca
      description: Strong Customer Authentication information returned in API responses.
      allOf:
      - $ref: '#/components/schemas/Sca'
      - title: Sca Response Details
        description: Strong Customer Authentication details in response.
        properties:
          aspspRedAdr:
            title: ASPSP Redirect Address
            type: string
            format: uri
            description: ASPSP Redirect URI.
    ConsentInformationCommon:
      title: ConsentInformation
      description: Common metadata describing the lifecycle and status of a consent resource.
      type: object
      properties:
        consentId:
          title: Consent Number
          description: Consent No
          example: B230WDS
          type: string
          minLength: 1
          maxLength: 128
        creationTime:
          title: Creation Time
          description: Creation Time
          type: string
          format: date-time
          example: '2021-03-25T06:30:22+03:00'
        updateTime:
          title: Update Time
          description: Update Time
          type: string
          format: date-time
          example: '2021-03-25T06:30:22+03:00'
        consentStatus:
          title: Consent Status
          description: Consent Status
          example: AWAIT_AUTHORIZATION
          type: string
          enum:
          - AWAIT_AUTHORIZATION
          - AUTHORIZED
          - REJECTED
          - REVOKED
          - EXPIRED
          - CONSUMED
      required:
      - consentId
      - creationTime
      - updateTime
      - consentStatus
    AccountInformationConsentRequest:
      title: AccountInformationConsentRequest
      description: Payload used by the TPP to create an account information consent request.
      type: object
      properties:
        sca:
          $ref: '#/components/schemas/Sca'
        accountInfo:
          $ref: '#/components/schemas/AccountInformation'
      required:
      - sca
      - accountInfo
    AccountInformation:
      title: AccountInformation
      description: Container for account access permissions requested or granted under the consent.
      type: object
      properties:
        permissionInfo:
          $ref: '#/components/schemas/PermissionInformation'
      required:
      - permissionInfo
    Service-Error-Response:
      type: object
      title: ServiceErrorResponse
      description: Error payload returned when the backend service cannot process a validly routed TPP request.
      required:
      - error_details
      properties:
        ref_id:
          type: string
          maxLength: 60
          description: Unique ID for the transaction.
          title: Identification Reference
        error_details:
          type: array
          items:
            $ref: '#/components/schemas/Error-Detail'
          title: The details of the error.
    Gateway-Error-Response:
      type: object
      title: Gateway-Error-Response
      description: This refers to an issue encountered by an API Gateway handling the request.
      required:
      - httpCode
      properties:
        httpCode:
          type: string
          maxLength: 3
          description: Numeric HTTP Status code
          title: httpCode
          example: '400'
        httpMessage:
          type: string
          maxLength: 128
          description: HTTP error message
          title: httpMessage
          example: Bad Request
        moreInformation:
          type: string
          maxLength: 128
          description: Additional information with HTTP error message
          title: moreInformation
          example: please provide valid value for request
    Error-Detail:
      type: object
      title: The details of the error.
      description: Detailed issue information for a service error, including reason, remediation, and code.
      properties:
        issue:
          type: string
          maxLength: 200
          description: More details about the issue.
          title: issue
        action:
          type: string
          maxLength: 350
          description: Corrective action to be taken to resolve the issue.
          title: action
        code:
          type: string
          maxLength: 8
          description: System-generated unique code for the issue.
          title: code
    PermissionInformation:
      title: PermissionInformation
      description: Permission scope and validity window granted through the account information consent.
      type: object
      properties:
        permissionType:
          title: Permission Type
          type: array
          items:
            title: Permission Type Item
            type: string
            enum:
            - BASIC_ACCOUNT_INFORMATION
            - DETAILED_ACCOUNT_INFORMATION
            - BALANCE_INFORMATION
            - BASIC_TRANSACTION_INFORMATION
            - DETAILED_TRANSACTION_INFORMATION
        accessPermissionEndDate:
          title: Access Permission End Date
          type: string
          format: date-time
        accountTransactionStartDateTime:
          title: Account Transaction Start Date Time
          type: string
          format: date-time
        accountTransactionEndDateTime:
          title: Account Transaction End Date Time
          type: string
          format: date-time
      required:
      - permissionType
      - accessPermissionEndDate
    AccountInformationConsent:
      title: AccountInformationConsent
      description: Consent resource returned after consent creation, including status, SCA, and permission details.
      type: object
      properties:
        consentInfo:
          $ref: '#/components/schemas/ConsentInformationCommon'
        sca:
          $ref: '#/components/schemas/ScaResponse'
        accountInfo:
          $ref: '#/components/schemas/AccountInformation'
      required:
      - consentInfo
      - sca
      - accountInfo
    Sca:
      title: Sca
      description: Strong Customer Authentication parameters used to complete PSU authorization for consent.
      type: object
      properties:
        tppRedirectUrl:
          title: Tpp Redirect URL
          type: string
          format: uri
          description: Tpp Redirect URI.
        notificationUrl:
          title: Notification URL
          type: string
          format: uri
          description: Notification URI.
        authCmpTime:
          title: Authentication Completion Time
          type: string
          format: date-time
          description: Authorization completion time.
    Common-Error-Response:
      title: Common Error Response
      description: Wrapper schema for responses that may return either gateway or service error payloads.
      oneOf:
      - $ref: '#/components/schemas/Gateway-Error-Response'
      - $ref: '#/components/schemas/Service-Error-Response'
    GetConsentInformation:
      title: ConsentInformation
      description: Consent metadata for inquiry responses, including optional cancellation detail.
      allOf:
      - $ref: '#/components/schemas/ConsentInformationCommon'
      - title: Consent Cancellation Details
        description: Strong Customer Authentication details in response.
        properties:
          consentCancelDetailCode:
            title: Consent Cancel Detail Code
            type: string
            enum:
            - REVOCATION_BY_ASPSP_UPON_USERS_REQUEST
            - REVOCATION_BY_TPP_UPON_USERS_REQUEST
            - TIMEOUT_PENDING_AUTHORIZATION
            - TIMEOUT_AUTHORIZED
            - TIMEOUT_AUTHORIZATION_NOT_TURNED_INTO_PAYMENT
      required:
      - consentId
      - creationTime
      - updateTime
      - consentStatus
    GetAccountInformationConsent:
      title: AccountInformationConsent
      description: Consent resource returned by consent inquiry for the provided consent identifier.
      type: object
      properties:
        consentInfo:
          $ref: '#/components/schemas/GetConsentInformation'
        sca:
          $ref: '#/components/schemas/ScaResponse'
        accountInfo:
          $ref: '#/components/schemas/AccountInformation'
      required:
      - consentInfo
      - sca
      - accountInfo
  headers:
    Request-ID:
      description: The request identifier specific to the call determined by the PSP initiating the request.
      schema:
        type: string
        minLength: 1
        maxLength: 36
    TPP-Code:
      description: The code of the Authorized Payment Service Provider sending the request. Required if the consent_id is used.
      schema:
        type: string
        minLength: 4
        maxLength: 4
        pattern: '[0-9][0-9][0-9][0-9]'
    Group-ID:
      description: The request identifier specific to the transaction flow determined by the PSP initiating the request.
      schema:
        type: string
        minLength: 1
        maxLength: 36
  parameters:
    Consent-Id-Path:
      in: path
      name: consentId
      required: true
      description: Unique identifier of the account information consent resource used for inquiry and deletion operations.
      schema:
        type: string
        minLength: 1
        maxLength: 128
    Group-ID:
      in: header
      name: Group-ID
      required: true
      schema:
        type: string
        title: Group-ID
        minLength: 1
        maxLength: 36
      description: The request identifier specific to the transaction flow determined by the PSP initiating the request.
    Request-ID:
      in: header
      name: Request-ID
      required: true
      schema:
        type: string
        title: Request-ID
        minLength: 1
        maxLength: 36
      description: The request identifier specific to the call determined by the PSP initiating the request.
    TPP-Code:
      in: header
      name: TPP-Code
      required: true
      schema:
        type: string
        title: TPP-Code
        minLength: 4
        maxLength: 4
        pattern: '[0-9][0-9][0-9][0-9]'
      description: The code of the Authorized Payment Service Provider sending the request. Required if the consent_id is used.
    PSU-IP-Address:
      in: header
      name: PSU-IP-Address
      required: true
      schema:
        type: string
        title: PSU-IP-Address
        minLength: 1
        maxLength: 15
      description: PSU-IP address of the payment service user (ipv4). Required if the consent_id is used in the request.
    Date:
      in: header
      name: Date
      required: true
      schema:
        type: string
        title: <day-name>, <day> <month> <year> <hour>:<minute>:<second> GMT
        pattern: (Mon|Tue|Wed|Thu|Fri|Sat|Sun), \d{1,2} (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) \d{4} \d{2}:\d{2}:\d{2} GMT$
      description: 'Date and time when the request is created/sent by the TPP. <br> <br> <b> Format: </b> day-name, day month year hour:minute:second GMT <br> (for example, Mon, 8 Jul 2026 14:25:30 GMT).'
  securitySchemes:
    oAuth:
      type: oauth2
      flows:
        clientCredentials:
          tokenUrl: /authenticationservices/v3/oauth/token
          scopes:
            authenticationservices/v1: Access to Accounts, Balances, Transactions Information
    auth:
      type: oauth2
      flows:
        clientCredentials:
          tokenUrl: https://secure.api-preprod.bkm.com.tr/oauth-provider/oauth2/token
          scopes:
            account_information: Account Information