Chuyển tới nội dung chính

Giao dịch đã thực hiện

API này trả về danh sách các giao dịch đã thực hiện (mua/bán) trong danh mục Nebula, cho phép theo dõi lịch sử hoạt động.

HTTP request

  • URL: /api/personalize/v1/partner/nebula-ultra/profiles/portfolio/transactions
  • Method: GET
  • Content Type: None
  • Response Type: application/json

Tham số header

HeaderMô tảKiểu dữ liệuBắt buộc
X-Api-KeyKhóa duy nhất.string

Tham Số Truy Vấn (Query Parameters)

Tên Tham SốKiểu Dữ LiệuBắt buộcMô Tả
externalUserIdstringUserId của đối tác.
typestringkhôngLoại portfolio:
- backtest: Hiệu suất quá khứ (default)
- paper: Giao dịch giả lập
- live: Dành cho bạn
pagestringkhôngTrang dữ liệu cần lấy, default: 0.
sizestringkhôngSố bản ghi của một trang, default: 10.
recvWindowstringkhôngThời gian chấp nhận (ms), default: 5000.
timestampstringUnix timestamp (milliseconds).
signaturestringHMAC-SHA256 signature.

Phản Hồi (Response)

Response Mẫu

{
"status": 200,
"message": "Success",
"total": 593,
"data": [
{
"ticker": "BVH",
"action": "BUY",
"price": 38686.93,
"priceClose": 38552.68325,
"quantity": 39800,
"timestamp": "2020-04-06T00:00:00.000Z"
},
{
"ticker": "BVH",
"action": "BUY",
"price": 40867.54,
"priceClose": 40725.2654,
"quantity": 37200,
"timestamp": "2020-04-07T00:00:00.000Z"
},
{
"ticker": "BVH",
"action": "BUY",
"price": 40867.54,
"priceClose": 40725.2654,
"quantity": 35300,
"timestamp": "2020-04-08T00:00:00.000Z"
},
{
"ticker": "BVH",
"action": "BUY",
"price": 40354.75,
"priceClose": 40214.0696,
"quantity": 35400,
"timestamp": "2020-04-09T00:00:00.000Z"
},
{
"ticker": "BVH",
"action": "BUY",
"price": 39328.17,
"priceClose": 39191.678,
"quantity": 9600,
"timestamp": "2020-04-10T00:00:00.000Z"
},
{
"ticker": "BVH",
"action": "BUY",
"price": 39541.91,
"priceClose": 39404.67625,
"quantity": 3200,
"timestamp": "2020-04-13T00:00:00.000Z"
},
{
"priceClose": 39362.0766,
"timestamp": "2020-04-14T00:00:00.000Z"
}
]
}

Chi Tiết Tham Số Response

Tên Thuộc TínhKiểu Dữ LiệuMô Tả
statusnumberMã trạng thái HTTP.
messagestringThông báo kết quả xử lý.
totalnumberTổng số giao dịch.
dataarray (Xem chi tiết)Dữ liệu danh sách các giao dịch.

Cấu trúc thuộc tính data

Quay lại

Tên Thuộc TínhKiểu Dữ LiệuMô Tả
tickerstringMã cổ phiếu.
actionstringLoại lệnh:
- BUY: mua
- SELL: bán
pricenumberGiá thực hiện.
priceClosenumberGiá đóng cửa.
quantitynumberSố lượng.
timestampstringNgày thực hiện (Định dạng: yyyy-MM-dd'T'HH:mm:ss.SSS'Z').

CREDENTIALS

* Timestamp và Signature sẽ được tự động tạo khi gọi API

RESPONSE200

{
"status": 200,
"message": "Success",
"total": 593,
"data": [
{
"ticker": "BVH",
"action": "BUY",
"price": 38686.93,
"priceClose": 38552.68325,
"quantity": 39800,
"timestamp": "2020-04-06T00:00:00.000Z"
},
{
"ticker": "BVH",
"action": "BUY",
"price": 40867.54,
"priceClose": 40725.2654,
"quantity": 37200,
"timestamp": "2020-04-07T00:00:00.000Z"
},
{
"ticker": "BVH",
"action": "BUY",
"price": 40867.54,
"priceClose": 40725.2654,
"quantity": 35300,
"timestamp": "2020-04-08T00:00:00.000Z"
},
{
"ticker": "BVH",
"action": "BUY",
"price": 40354.75,
"priceClose": 40214.0696,
"quantity": 35400,
"timestamp": "2020-04-09T00:00:00.000Z"
},
{
"ticker": "BVH",
"action": "BUY",
"price": 39328.17,
"priceClose": 39191.678,
"quantity": 9600,
"timestamp": "2020-04-10T00:00:00.000Z"
},
{
"ticker": "BVH",
"action": "BUY",
"price": 39541.91,
"priceClose": 39404.67625,
"quantity": 3200,
"timestamp": "2020-04-13T00:00:00.000Z"
},
{
"priceClose": 39362.0766,
"timestamp": "2020-04-14T00:00:00.000Z"
}
]
}