Skip to content
Stock

Stock Account Details

Queries the stock holding-change detail, recording every change in a client's stock position quantity for reconciliation and traceability of asset movements.

Request parameters

  • Combine business filter conditions through filters (see the filters field descriptions below for available fields), and use page, page_size, and orderBy to control pagination and sorting.

Business notes

The data comes from the position-change records of a client's stock holdings.

Each record includes the business time, client information (client ID, name, aaid, securities account), account type, business classification (business code and its name, identifying the activity that caused the change), the stock code, direction (In for inflow / Out for outflow), the change quantity, the resulting position quantity, the payment reference number, and remarks.

It is typically used by back-office staff to reconcile increases and decreases in stock positions by client, stock code, time, and business code, and to trace each change back to its source order via the payment reference number.

Returns

On success, returns the matching record list along with pagination information. See the response definition for the meaning of each returned column.

POSThttps://b-api.lbkrs.com/v1/datasets/account_stock_holding_changes

Authorization

AuthorizationstringheaderRequired

Send the Broker ACCESS_TOKEN as Authorization: Bearer <token>.

Permission

account_balance_change.stock

The Broker ACCESS_TOKEN must be granted the permission above, or the call will be rejected.

Request body application/json

filtersobject

Filters. Combines business filters. Omit a filter field to disable that filter.

Child attributes
aaidstring

Client. Filters results by Client.

Pass the internal numeric ID of the customer's securities account (aaid), not the securities account number account_no (such as H00000000) or the customer ID member_id. One customer can have multiple aaid values.

aaid_liststring

Client List. Filters results by Client List.

counter_idstring

Stock Code. Filters results by Stock Code. Format is {type}/{market}/{code}, for example, stock ST/HK/700 or ST/US/AAPL, and option OP/US/AAPL270319C320000.

account_typestring

Account Type. Filters results by Account Type.

Allowed values: SETTLEMENT, BUSINESS, EXTERNAL, INTERNAL

Values
SETTLEMENT
BUSINESS
EXTERNAL
INTERNAL
updated_atobject

Updated At. Filters results by Updated At.

Child attributes
gtestring

Greater Than or Equal. Inclusive lower bound of the filter range.

ltestring

Less Than or Equal. Inclusive upper bound of the filter range.

done_atobject

Done At. Filters results by Done At.

Child attributes
gtestring

Greater Than or Equal. Inclusive lower bound of the filter range.

ltestring

Less Than or Equal. Inclusive upper bound of the filter range.

biz_codestring

Biz Code. Filters results by Biz Code.

Values are dynamic. Call GET /v1/datasets/refs/biz_code_to_name to retrieve the current data dictionary, and use the returned entry's key as this parameter's value.

transfer_biz_namestring

Biz Code Name. Filters results by Biz Code Name.

pageinteger

Page number to retrieve, starting from 1.

page_sizeinteger

Page Size. Number of records to return per page.

Responses

HTTP 200On success, returns paginated Stock Account Details records together with pagination metadata such as the page number, page size, and total record count.
Standard response envelopecodemessagedata
dataobjectdata structure
listarray<object>required

List. Returned value: List of list.

Child attributes
idstring

ID. Returned value: Unique identifier of the current record.

id_valstring

ID (raw value). Raw value of id. The id field contains the display value resolved through a dictionary or related record; this field contains the underlying code or ID.

done_atstring

Done At. Returned value: Done At. The date or time format follows the value returned by the API.

member_idstring

Member ID. Returned value: Member ID.

real_namestring

Name. Returned value: Name.

origin_idstring

A/C No. Returned value: A/C No.

account_typestring

Account Type. Returned value: Account Type.

biz_codestring

Biz Code. Returned value: Biz Code.

biz_code_valstring

Biz Code (raw value). Raw value of biz_code. The biz_code field contains the display value resolved through a dictionary or related record; this field contains the underlying code or ID.

counter_idstring

Stock Code. Returned value: Stock Code.

statement_nostring

Statement Transaction No. Returned value: Statement Transaction No.

report_directionstring

Direction. Returned value: Direction.

report_direction_valstring

Direction (raw value). Raw value of report_direction. The report_direction field contains the display value resolved through a dictionary or related record; this field contains the underlying code or ID.

quantitystring

Qty. Returned value: Qty.

last_business_quantitystring

Outstanding Quantity. Returned value: Outstanding Quantity.

last_settlement_quantitystring

Settled Quantity. Returned value: Settled Quantity.

total_quantitystring

Total Quantity. Returned value: Total Quantity.

updated_atstring

Updated At. Returned value: Updated At. The date or time format follows the value returned by the API.

multilingual_remarkstring

Remark. Returned value: Remark.

totalintegerrequired

Total. Returned value: Total number of matching records, used for pagination.

HTTP 400Bad request. Check the business error code in code and the error details in message.
Standard response envelopecodemessagedata
dataobjectdata structure

No nested fields

HTTP 401The user is not authenticated, or the login session has expired.
Standard response envelopecodemessagedata
dataobjectdata structure

No nested fields

HTTP 403The current account is not authorized to use this feature. Grant the required permission to the account in User Permission.
Standard response envelopecodemessagedata
dataobjectdata structure

No nested fields

HTTP 408The request timed out. Check the business error code in code and the error details in message.
Standard response envelopecodemessagedata
dataobjectdata structure

No nested fields

Whale Docs