> ## Documentation Index
> Fetch the complete documentation index at: https://hoalulab.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Tỷ lệ margin và rủi ro

> Lấy dư nợ gốc, dư nợ lãi, Rtt và các tỷ lệ margin của tài khoản margin.



## OpenAPI

````yaml /vi/openapi/tcbs.v1.openapi.yaml get /hydros/v1/account/{accountNo}/risk
openapi: 3.0.3
info:
  title: TCBS iFlash Open API
  description: REST APIs for trading stocks and derivatives on TCBS.
  version: 1.0.0
  contact:
    email: openapi@tcbs.com.vn
servers:
  - url: https://openapi.tcbs.com.vn
    description: Production
security:
  - bearerAuth: []
tags:
  - name: authentication
    description: Xác thực và cấp token truy cập.
    x-group: Xác thực
  - name: account
    description: Thông tin tài khoản, tài sản và hạn mức.
    x-group: Tài khoản
  - name: market-data
    description: Dữ liệu chứng khoán và phái sinh.
    x-group: Dữ liệu thị trường
  - name: cash
    description: Giao dịch và thông tin tiền.
    x-group: Tiền
  - name: stock-orders
    description: Đặt, sửa, hủy và tra cứu lệnh cổ phiếu.
    x-group: Lệnh cổ phiếu
  - name: derivative-orders
    description: Đặt, sửa, hủy và tra cứu lệnh phái sinh.
    x-group: Lệnh phái sinh
paths:
  /hydros/v1/account/{accountNo}/risk:
    get:
      tags:
        - account
      summary: Tỷ lệ margin và rủi ro
      description: Lấy dư nợ gốc, dư nợ lãi, Rtt và các tỷ lệ margin của tài khoản margin.
      operationId: getHydrosAccountAccountNoRisk
      parameters:
        - name: accountNo
          in: path
          required: true
          description: Số tiểu khoản margin.
          schema:
            type: string
      responses:
        '200':
          description: Phản hồi thành công
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                  properties:
                    accountNo:
                      type: string
                      description: Số tiểu khoản.
                    rtt:
                      type: number
                      format: double
                      description: Rtt thực tế.
                    outstanding:
                      type: number
                      format: double
                      description: Tổng nợ gốc.
                    accruedInterest:
                      type: number
                      format: double
                      description: Tổng nợ lãi.
                    dueAmount:
                      type: number
                      format: double
                      description: Nợ đến hạn.
                    overdueAmount:
                      type: number
                      format: double
                      description: Nợ quá hạn.
                    totalFeeDebt:
                      type: number
                      format: double
                      description: Tổng nợ phí (Phí marginsure).
                    riskPolicy:
                      type: object
                      properties:
                        initialMargin:
                          type: number
                          format: double
                          description: Tỷ lệ ký quỹ ban đầu.
                        maintenanceMargin:
                          type: number
                          format: double
                          description: Tỷ lệ duy trì.
                        liquidationMargin:
                          type: number
                          format: double
                          description: Tỷ lệ cảnh báo.
                    riskStatus:
                      type: object
                      properties:
                        code:
                          type: string
                          description: Trạng thái RTT.
                        description:
                          type: string
                          description: Mô tả trạng thái RTT.
              example:
                - accountNo: 0001I97267
                  rtt: 99.95
                  outstanding: 8858766677
                  accruedInterest: 18638724
                  dueAmount: 34621881
                  overdueAmount: 34621881
                  totalFeeDebt: 8885876
                  riskPolicy:
                    initialMargin: 100
                    maintenanceMargin: 80
                    liquidationMargin: 30
                  riskStatus:
                    code: SAFE
                    description: An toàn
        '401':
          $ref: '#/components/responses/Unauthorized'
components:
  responses:
    Unauthorized:
      description: Không xác thực — thiếu, sai hoặc không hợp lệ Bearer token.
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.