Files Specification: Prepared By: I.T. Division

You might also like

You are on page 1of 13

The Karachi Stock Exchange (G) Ltd.

Download Files
Specification

Prepared By:
I.T. Division

October 8, 2001
I.T. Division

This document contains proprietary information and is not intended for public
distribution. All trademarks, logos and trade names within this document are the property
of The Karachi Stock Exchange (G) Ltd., unless otherwise stated. All rights reserved. No
part of this document may be reproduced or transmitted in any form by any means,
electronic, mechanical, photocopying, recording, or otherwise, without prior written
permission of The Karachi Stock Exchange (G) Ltd.

While all reasonable care has been taken in the preparation of this document, no liability
is accepted by the authors, The Karachi Stock Exchange (G) Ltd., for any errors,
omissions or misstatements it may contain, or for any loss or damage, howsoever
occasioned, to any person relying on any statement or omission in this document.

Copyright 1997 The Karachi Stock Exchange (G) Ltd.

Any questions regarding this document others should be forwarded to:

I.T. Division
The Karachi Stock Exchange (G) Ltd.
Off I.I. Chundrigar Road,
Exchange Road,
Karachi 74000
Pakistan

Phone: 92-21-111-012-345
Fax: 92-21-2415136
E-mail: info@kse.com.pk
Attention: Chief Manager, I.T. Division

October 8, 2001 The Data Feed Specification 1


I.T. Division

Document Change Log


As documents are revised, important information is added or removed. Enter changes in
this table so users know what has changed.

Refer to this table to make sure you haven’t missed the latest information

Date(yy/mm/dd) Changed By Description of Change Reason for Change

2001/06/25 Karachi Stock New features addition To provide more


Exchange data for our users
(I.T Division)
2001/07/11 Karachi Stock
Exchange New features addition Forward Trading
(I.T Division) (Future Volume)

2001/10/08 Karachi Stock New Symbolic End-User


Exchange Representation of Future Requirements
(I.T Division) Bids and Trading. Symbol
Code is replaced by
Company Code

October 8, 2001 The Data Feed Specification 2


I.T. Division

KSE Feed Specification


Karachi Stock Exchange on-line feed contain different type of records, each record
identify by first character of the record.

We used pipe (|) sign as field separator within record and astaric (*) sign and new line
character as a record separator.

Record types and field specifications are as follows.

Record identify by Record Type Length in Total


---------------------- ------------------- ---------------------
S Market Static’s 57 character
V Future Market Static’s 57 character
A Out-cry 83 character
K KATS 83 character
O Cross Trades (C to C) 83 character
F Future 83 character
U Update/Cancel 83 character
N Announcement 97 characters

Market Statistics Record

Field 1. Record Identifier One Character


Field 2 Previous Day Volume of the Market 10 Character padded with zero
Field 3 Current Day Volume of the Market 10 Character padded with zero
Field 4 Previous Day KSE100 Index Level 7 Character padded with zero
Field 5 Current Day KSE100 Index Level 7 Character padded with zero
Field 6 Number of Companies Advance 5 Character padded with zero
Field 7 Number of Companies Decline 5 Character padded with zero
Field 8 Number of Companies un-change 5 Character padded with zero

NOTE: Field Number 4 and 5 are absolute Integer. Before transmitting these field
we multiply them by 100.00, that’s why these fields have to be converted
to their original value after receive.

Each Field (except Field 8) is delimited by a pipe sign character (|).


Asterik (*) shows the end of record.

October 8, 2001 The Data Feed Specification 3


I.T. Division

Future Market Statistics Record

Field 1. Record Identifier One Character


Field 2 Previous Day Volume of the Market 10 Character padded with zero
Field 3 Current Day Volume of the Market 10 Character padded with zero
Field 4 Previous Day KSE100 Index Level 7 Character padded with zero
Field 5 Current Day KSE100 Index Level 7 Character padded with zero
Field 6 Number of Companies Advance 5 Character padded with zero
Field 7 Number of Companies Decline 5 Character padded with zero
Field 8 Number of Companies un-change 5 Character padded with zero

NOTE: Each Field (except Field 8) is delimited by a pipe sign character (|).
Asterik (*) shows the end of record.

Out-cry Record

Field 1. Record Identifier One Character


Field 2 Sector Code 2 Characters
Field 3 Company Code 12 Character
Field 4 Company Name 15 Character
Field 5 Trade Sequence Number 5 Character padded with zero
Field 6 Opening Rate 6 Character padded with zero
Field 7 Total Turnover 10 Character padded with zero
Field 8 Rate of this trade 6 Character padded with zero
Field 9 Turnover of this trade 8 Character padded with zero
Field 10 Calling Order 9 Character padded with zero

NOTE: Field Number 6 and 8 are absolute Integer. Before transmitting these field
we multiply them by 100.00, that’s why these fields have to be converted
to their original value after receive.

Each Field (except Field 10) is delimited by a pipe sign character (|).
Asterik (*) shows the end of record.

KATS Record

Field 1. Record Identifier One Character


Field 2 Sector Code 2 Characters
Field 3 Company Code 12 Character
Field 4 Company Name 15 Character
Field 5 Trade Sequence Number 5 Character padded with zero
Field 6 Opening Rate 6 Character padded with zero
Field 7 Total Turnover 10 Character padded with zero
Field 8 Rate of this trade 6 Character padded with zero
Field 9 Turnover of this trade 8 Character padded with zero

October 8, 2001 The Data Feed Specification 4


I.T. Division

Field 10 Calling Order 9 Character padded with zero

NOTE: Field Number 6 and 8 are absolute Integer. Before transmitting these field
we multiply them by 100.00, that’s why these fields have to be converted
to their original value after receive.

Each Field (except Field 10) is delimited by a pipe sign character (|).
Asterik (*) shows the end of record.

Cross Trade (C To C)

Field 1. Record Identifier One Character


Field 2 Sector Code 2 Characters
Field 3 Company Code 12 Character
Field 4 Company Name 15 Character
Field 5 Trade Sequence Number 5 Character padded with zero
Field 6 Opening Rate 6 Character padded with zero
Field 7 Total Turnover 10 Character padded with zero
Field 8 Rate of this trade 6 Character padded with zero
Field 9 Turnover of this trade 8 Character padded with zero
Field 10 Calling Order 9 Character padded with zero

NOTE: Each Field (except Field 10) is delimited by a pipe sign character (|).
Asterik (*) shows the end of record.

Future Record

Field 1. Record Identifier One Character


Field 2 Sector Code 2 Characters
Field 3 Company Code 12 Character
Field 4 Company Name 15 Character
Field 5 Trade Sequence Number 5 Character padded with zero
Field 6 Opening Rate 6 Character padded with zero
Field 7 Total Turnover 10 Character padded with zero
Field 8 Rate of this trade 6 Character padded with zero
Field 9 Turnover of this trade 8 Character padded with zero
Field 10 Calling Order 9 Character padded with zero

NOTE: Each Field (except Field 10) is delimited by a pipe sign character (|).
Asterik (*) shows the end of record.

October 8, 2001 The Data Feed Specification 5


I.T. Division

Update/ Cancel Record

Field 1. Record Identifier One Character


Field 2 Sector Code 2 Characters
Field 3 Company Code 12 Character
Field 4 Company Name 15 Character
Field 5 Trade Sequence Number 5 Character padded with zero
Field 6 Opening Rate 6 Character padded with zero
Field 7 Total Turnover 10 Character padded with zero
Field 8 Rate of this trade 6 Character padded with zero
Field 9 Turnover of this trade 8 Character padded with zero
Field 10 Calling Order 9 Character padded with zero

NOTE: Each Field (except Field 10) is delimited by a pipe sign character (|).
Asterik (*) shows the end of record.

Announcement

Field 1. Record Identifier One Character


Field 2 Company Short Name 15 Character
Field 3 Announcement Date 9 Character
Field 4 Announcement Time 8 Character padded with zero
Field 5 Announcement Description 60 Character padded with zero

Note : Each Field (except Field 5) is delimited by a pipe sign character (|). Asterik (*)
shows the end of record.

October 8, 2001 The Data Feed Specification 6


I.T. Division

These feed specifications are subject to change. Any changes in this feed will be
communicated to all the parties accordingly time to time basis.

FEED SAMPLE:
V|0004129500|0007379000|0000000|0000000|00000|00000|00000*
S|0045523900|0078960280|0111231|0114119|00100|00034|00025*
K|05|AICL |Adamjee Ins |00001|002140|0000000500|002150|00000500|842006530*
K|04|BOPL |B.O.Punjab |00001|000630|0000001000|000630|00001000|842006530*
K|04|BOPL |B.O.Punjab |00002|000630|0000002000|000630|00001000|842006530*
O|20|ENGRO |Engro Chem. |00001|004520|0000002000|004550|00002000|892403714*
O|20|ENGRO |Engro Chem. |00002|004520|0000004000|004550|00002000|892403714*
K|20|ENGRO |Engro Chem. |00003|004520|0000004100|004550|00000100|842006530*
V|0004129500|0007379000|0000000|0000000|00000|00000|00000*
S|0045523900|0078960280|0111231|0114119|00100|00034|00025*
K|20|ENGRO |Engro Chem. |00004|004520|0000005300|004550|00001200|842006530*
K|20|ENGRO |Engro Chem. |00005|004520|0000006300|004550|00001000|842006530*
K|20|ENGRO |Engro Chem. |00006|004520|0000006800|004550|00000500|842006530*
K|20|ENGRO |Engro Chem. |00007|004520|0000006900|004550|00000100|842006530*
K|20|ENGRO |Engro Chem. |00008|004520|0000007400|004550|00000500|842006530*
K|20|ENGRO |Engro Chem. |00009|004520|0000007600|004550|00000200|842006530*
V|0004129500|0007379000|0000000|0000000|00000|00000|00000*
S|0045523900|0078960280|0111231|0114119|00100|00034|00025*
K|20|ENGRO |Engro Chem. |00010|004520|0000009000|004550|00001400|842006530*
K|20|ENGRO |Engro Chem. |00011|004520|0000009500|004550|00000500|842006530*
K|20|ENGRO |Engro Chem. |00012|004520|0000013600|004550|00004100|842006530*
K|20|ENGRO |Engro Chem. |00013|004520|0000014500|004550|00000900|842006530*
K|20|ENGRO |Engro Chem. |00014|004520|0000014600|004550|00000100|842006530*
K|20|ENGRO |Engro Chem. |00015|004520|0000020500|004550|00005900|842006530*

October 8, 2001 The Data Feed Specification 7


I.T. Division

Bids Specification:
This feed contains different type of records, each record identify by first character of the record.
We used pipe (|) sign as field separator within record and astiric (*) sign and newline character
as a record separator.

Fields Specification

Field 1. Record Identifier One Character


Field 2 Company Symbol Code 12 Character
Field 3 Company Short Name 15 Character
Field 4 Bid Sequence Number 8 Character (decimal)
Field 5 Bid Volume 8 Character (decimal)
Field 6 Bid Price 7 Character (float)(4 digits before
decimal, one point, two digits after
decimal)
Field 7 Ask Price 7 Character (float)(4 digits before
decimal, one point, two digits after
decimal)
Field 8 Ask Volume 8 Character (decimal)

Total Length : 73 characters


Fields Description:

1. Record Identifier: This is a record identifier ( Best Market ) “B”.


2. Symbol Code: This field holds the symbols of Companies such as “PSOC”
is a symbol code of Pakistan State Oil etc.
3. Company Name (Short): This field holds the company descriptions of symbol code
such as Pakistan State Oil is the company description of Symbol “PSOC”.
4. Sequence id: This field holds the sequences for instance 1268,1269 … etc.
5. Bid Volume: This field holds bid volume.
6. Bid Price: This field holds best bid price.This column is updated instantly ,
as when a new bid price is committed
7. Ask Price: This field holds best ask price. This column is updated instantly ,
as when a new ask price is committed
8. Ask Volume: This field holds ask volume.

Note : Each Field (except Field 8) is delimited by a pipe sign character (|). Asterik (*)
shows the end of record.

FEEDSAMPLE:

Symbol Code Company Desc Seq Id Bid Volume Bid Price Ask Price AskVolume
B| FFCJ | FFC JORDAN | 1268 | 58000 | 12.10 | 12.15 | 29500 *
B| FFCJ | FFC JORDAN | 1269 | 58000 | 12.10 | 12.15 | 24500 *
B| FFCJ | FFC JORDAN | 1270 | 58000 | 12.10 | 12.15 | 16500 *
B| FFCJ | FFC JORDAN | 1272 | 58000 | 12.10 | 12.15 | 11500 *

October 8, 2001 The Data Feed Specification 8


I.T. Division

Future Bids Specification:


This feed contains different type of records, each record identify by first character of the record.
We used pipe (|) sign as field separator within record and astiric (*) sign and newline character
as a record separator.

Fields Specification

Field 1. Record Identifier One Character


Field 2 Company Symbol Code 12 Character
Field 3 Company Short Name 15 Character
Field 4 Bid Sequence Number 8 Character (decimal)
Field 5 Bid Volume 8 Character (decimal)
Field 6 Bid Price 7 Character (float)(4 digits before
decimal, one point, two digits after
decimal)
Field 7 Ask Price 7 Character (float)(4 digits before
decimal, one point, two digits after
decimal)
Field 8 Ask Volume 8 Character (decimal)

Total Length : 73 characters


Fields Description:

1) Record Identifier: This is a record identifier ( Best Market ) “P”.


2) Symbol Code: This field holds the symbols of Companies such as “PSOC-XXX”
is a symbol code of Pakistan State Oil etc. where XXX is the month symbol
Month Symbols
Name Code
January JAN
February FEB
March MAR
April APR
May MAY
June JUN
July JUL
August AUG
September SEP
October OCT
November NOV
December DEC

3) Company Name (Short): This field holds the company descriptions of symbol code
such as Pakistan State Oil is the company description of Symbol “PSOC”.
4) Sequence id: This field holds the sequences for instance 1268,1269 … etc.
5) Bid Volume: This field holds bid volume.
6) Bid Price: This field holds best bid price.This column is updated instantly ,
as when a new bid price is committed
7) Ask Price: This field holds best ask price. This column is updated instantly ,

October 8, 2001 The Data Feed Specification 9


I.T. Division

as when a new ask price is committed


8) Ask Volume: This field holds ask volume.

Note : Each Field (except Field 8) is delimited by a pipe sign character (|). Asterik (*)
shows the end of record.

FEEDSAMPLE:

Symbol Code Company Desc Seq Id Bid Volume Bid Price Ask Price AskVolume
P|MCBL-SEP |MCBL-SEP XD |00000005|00001000|0022.00|0023.00|00001000*
P|HUBC-SEP |HUBC-SEP |00000766|00002500|0016.05|0016.20|00010000*

October 8, 2001 The Data Feed Specification 10


I.T. Division

Market Summary Specification

Field 1. Date
Field 2 Symbol Code
Field 3 Sector Code
Field 4 Company Short Name
Field 5 Opening Rate
Field 6 High Rate
Field 7 Low Rate
Field 8 Current Rate
Field 9 Current Turnover

Top 30 Companies (Decreased) Specification

Field 1. Company Short Name


Field 2 Opening Rate
Field 3 High Rate
Field 4 Low Rate
Field 5 Current Rate
Field 6 Current Turnover
Field 7 Percentage

All Share Index Specification

Field 1. Sector Code


Field 2 Sector Name
Field 3 Market Capitalization
Field 4 Current Turnover
Field 5 Total New Traded
Field 6 Previous Index
Field 7 Current Index
Field 8 Index Net Change
Field 9 Market Capitalization Percentage
Field 10 Market Traded Percentage

Top 30 Companies (Volume) Specification

Field 1. Company Short Name


Field 2 Opening Rate
Field 3 High Rate
Field 4 Low Rate
Field 5 Current Rate
Field 6 Current Turnover

October 8, 2001 The Data Feed Specification 11


I.T. Division

Top 30 Companies (Increased) Specification

Field 1. Company Short Name


Field 2 Opening Rate
Field 3 High Rate
Field 4 Low Rate
Field 5 Current Rate
Field 6 Current Turnover
Field 7 Percentage

Index Fluctuation Specification

Field 1. Time
Field 2 KSE100 Index
Field 3 All Share Index
Field 4 KSE30 Index

KSE 100 Index Companies Specification

Field 1. Company Short Name


Field 2 High Rate
Field 3 Low Rate
Field 4 Current Rate
Field 5 Current Out Standing Shares
Field 6 Percentage
Field 7 Current Market Capitalization

Companies’ Info Specification

Field 1. Company Code


Field 2 Symbol Code
Field 3 Company Long Name
Field 4 Sector Code
Field 5 Sector Name
Field 6 Outstanding Shares

October 8, 2001 The Data Feed Specification 12

You might also like