100% found this document useful (3 votes)
1K views148 pages

© 2007, Cognizant Technology Solutions Confidential

Uploaded by

Sushma V Kumar
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
100% found this document useful (3 votes)
1K views148 pages

© 2007, Cognizant Technology Solutions Confidential

Uploaded by

Sushma V Kumar
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 148

OFS

© 2007, Cognizant Technology Solutions Confidential


What is the need for OFS?

Data ware house

T24
Swift interface
OFS

ATM

T24 Browser

© 2007, Cognizant Technology Solutions Confidential

Slide 2
OFS

Transaction Request
Enquiry Request

3 | ©2011, Cognizant
Module in T24
Only standard gateway to T24
Every single interaction with T24 is driven through OFS.
At the based
Works end ofon this session
a request youbased
– response should be able to
system
Enables III party systems to post requests and obtain
responses
Appreciate the need for OFS
Describe the message syntax for commonly used OFS
messages
Write OFS requests

4 | ©2011, Cognizant
T24 Structure

Native OFS format


XML format

5 | ©2011, Cognizant
OFS-SAMPLE

ACCOUNT,SAMPLE/I/PROCESS//2,
INPUTT/123456,34567,CUSTOMER=100724,CATEGORY
=1001,CURRENCY=USD
Request specifies application, function, fields and values
Should contain values for all mandatory fields.
OFS transaction requests cannot be used to update live files (similar to user
input).
Simple comma delimited format
Some message parts further subdivided using
slashes

6 | ©2011, Cognizant
Transaction Request - Message Syntax

Operation Options User Transaction Message


, , , ,
Information ID Data

Operation
Contains the name of APPLICATION.
Example: ACCOUNT.
Options
Comprises of VERSION-
NAME/FUNCTION/PROCESS TYPE
/ GTS.CONTROL value/NO.OF.AUTHORISERS.

| ©2011, Cognizant

7
Transaction Request - Message Syntax cont…

Operation Options User Transaction Message


, , , ,
Information ID Data

Transaction ID
Contains transaction id of the record used in
the transaction.
Eg: 20548
Mandatory for See , Authorize , Delete &
function

| ©2011, Cognizant

8
Transaction Request - Examples
Request to Input
ACCOUNT,/I/PROCESS,
INPUTT/123456,34567,CUSTOMER=100724,CATEGORY=1001,CURRENCY=USD

Request to Authorise
ACCOUNT,/A,INPUTT/123456,34567

| ©2011, Cognizant
Workshop

Write a OFS message to input a SECTOR record with id 1200

Write a OFS message to authorise this SECTOR.

Write a OFS message to input a new ABBREVIATION called UL for


listing the USER records.

Write a OFS message to input a CUSTOMER record in T24. Use zero


authorisers in your message

| ©2011, Cognizant

10
Enquiry request – Message Syntax

ENQUIRY. User Enquiry Message


, , , ,
SELECT Information Name Data

| ©2011, Cognizant

12
Enquiry Request - Examples

Without criteria i.e. message data portion


ENQUIRY.SELECT,,INPUTT/654321,%ACCOUNT

With criteria
ENQUIRY.SELECT,,INPUTT/654321,%ACCOUNT,
ACCOUNT.NUMBER:EQ=11109

| ©2011, Cognizant

13
Workshop – Enquiry
Type Messages

Write an Enquiry type request to find the list of INDUSTRY records found
in yourT24 area

Write an Enquiry type request to find the current day’s balance summary
of an ACCOUNT (say for example 29987). (TIP: Use the enquiry
ACCT.BAL.TODAY)

| ©2011, Cognizant

14
What are the ways (and Modes )in which we use OFS ?

Batch processing
BATCH mode – for offline requests from third party
systems
Inter application processing
GLOBUS mode – for calling applications from local
code
Online processing
TELNET mode – for processing messages online
from third party systems
SESSION mode – for processing messages online
from browser

| ©2011, Cognizant
Routines and their functions
Routine Function Mode
OFS.QUEUE.MANAGER Phantom that picks request from the IN Batch
QUEUE

OFS.REQUEST.MANAGER Processes the message ALL

OFS.PARSER.OFS Validation of the message ALL


( For browser
requests, it is OFS.PARSER.XML)

OFS.ENQUIRY.MANAGER REQUEST MANAGER calls ENQUIRY ALL


MANAGER
to run an enquiry if the request is an
enquiry request
EB.PHANTOM This is the actual Batch
process that runs in the background

| ©2011, Cognizant
Routines and their functions
Routine Function Mode
OFS.PROCESS.MANAGER Called from BULK MANAGER for Online
messages that are standard
messages(Not BULK messages).Calls
SESSION MANAGER. Deals with
handling of the message.
OFS.ONLINE.MANAGER Listens to a request and Calls TELNET
OFS.REQUEST.MANAGER (Obsolete)

OFS.BULK.MANAGER Called when bulk OFS requests are Online


sent. Incorporates Transaction Block.
Any message that come in via online
mode will pass through BULK
MANAGER
OFS.SESSION.MANAGER Called by OFS.PROCESS.MANAGER Online
when the request is from the Browser
. Also handles token management.

| ©2011, Cognizant
OFS.SOURCE
Key Fields To Understand Now

Id

Source Type

In Queue Dir

Out Queue Dir

Syntax Type

Sample Data to fill


out

Id : TEST.BATCH

Source Type :BATCH

| ©2011, Cognizant

19
OFS.SOURCE cont
Key Fields To Understand Now

Id

Source Type

In Queue Dir

Out Queue Dir

Syntax Type

Sample Data to fill


out

Id : TEST.BATCH

Source Type :BATCH

| ©2011, Cognizant
In Queue Dir :TRGIN
20
EB.PHANTOM
Key fields with sample data
Fields Sample data
Id OFS.BATCH
Status Blank or ACTIVE
Phant Stop Blank or STOP
Req
Run Mode PHANTOM
Sleep secs 2
Globus In NONE
Pipe
Globus Out NONE
Pipe
Gts User Id OFSUSER1
Ofs Source TEST.BATCH
Run Routine OFS.QUEUE.MANAGER

| ©2011, Cognizant

21
Testing the batch mode

Sample enquiry
ENQUIRY.SELECT,,INPUTT/123456,%ACCOUNT
Create a record in your input queue (i.e. within TRGIN with an id
of say ENQACCT).
Enter the your enquiry into this record
Once processed, the request will be removed from the IN queue .
The response is written to the OUT queue into a record with the
same id.

OFS.QUEUE.M
ANAGER

| ©2011, Cognizant
EB.PHANTOM

EB.PHANTOM controls all phantom and interactive jobs in T24.


The control parameters for phantoms such as the name of the program to
execute, sleep time etc are specified here
We need to make OFS.QUEUE.MANAGER run as a phantom in order for
OFS to pick up requests from the IN queue and process it.

| ©2011, Cognizant

23
Check the output

Does your output look like this ?

Output of CT TRGOUT ENQACCT

| ©2011, Cognizant
One more test – a Transaction Request
ACCOUNT, /I/PROCESS, INPUTT/123123,,CUSTOMER=100724,CATEGORY=1001,
CURRENCY=USD

Note:
All the mandatory fields of the application
have to be filled.
The id will be automatically generated by the
system.

| ©2011, Cognizant
Authorise …
39087//1,CUSTOMER=100724:1:1,CATEGORY=1001:1:1,ACCOUNT.TITL
E.1=AAA SHIPPING COMPANY OF PANAMA:1:1,SHORT.TITLE=AAA
SHIPPING COMPANY OF
PANAMA:1:1,POSITION.TYPE=TR:1:1,CURRENCY=USD:1:1,CURRENCY.M
ARKET=1:1:1,ACCOUNT.OFFICER=27:1:1,CONDITION.GROUP=2:1:1,PA
SSBOOK=NO:1:1,OPEN.CATEGORY=1001:1:1,CHARGE.CCY=USD:1:1,CHA
RGE.MKT=1:1:1,INTEREST.CCY=USD:1:1,INTEREST.MKT=1:1:1,ALT.A
CCT.TYPE=LEGACY:1:1,ALLOW.NETTING=NO:1:1,SINGLE.LIMIT=Y:1:1
,RECORD.STATUS=INAU:1:1,CURR.NO=1:1:1,INPUTTER=2_OFSUSER1__
_OFS_TEST.BATCH:1:1,DATE.TIME=0811012041:1:1,CO.CODE=GB0010
001:1:1,DEPT.CODE=1:1:1

In the OFS response , what is the user id shown in the INPUTTER


field?

| ©2011, Cognizant
Problem-SAME AUTHORISER

When you sent another message via OFS to authorize this record (using
the same BATCH mode), you should have got an error message
“EB.RTN.SAME.NAME.AUTHORISER/INPUTTER”
This is because the user context for a Batch mode is that of GTS user
When you use the same batch record for inputting and authorising, you
use the same GTS user and therefore the inputter and authoriser will
be the same.

| ©2011, Cognizant

27
Important Points

Batch mode allows us ‘pump’ messages in a queue.


A queue may be a folder or a particular file within a folder
The important fields to setup in OFS.SOURCE are Id,Source Type,
In.Queue.Dir,Out.Queue.Dir,Syntax.Type
EB.PHANTOM must be configured to invoke OFS.QUEUE.MANAGER.
The important fields in EB.PHANTOM are Status , Phant Stop Req , Run
Mode,Sleep secs,Globus In Pipe,Globus Out Pipe,Gts User Id,Ofs
Source,Run Routine
When the Run Mode is specified as Phantom, the background process runs
under the SMS context of the user given in this field. This user name is
updated in the audit fields of OFS based transactions.
The Same Authoriser field in OFS.SOURCE is used to overcome the issue
of “same authoriser / inputter”

| ©2011, Cognizant
Transaction Response - Sample

You can see a (familiar?) OFS response message below

39087//1,CUSTOMER=100724:1:1,CATEGORY=1001:1:1,ACCOUNT.TITLE.1=AAA
SHIPPING COMPANY OF PANAMA:1:1,SHORT.TITLE=AAA SHIPPING COMPANY OF
PANAMA:1:1,POSITION.TYPE=TR:1:1,CURRENCY=USD:1:1,CURRENCY.MARKET=1
:1:1,ACCOUNT.OFFICER=27:1:1,CONDITION.GROUP=2:1:1,PASSBOOK=NO:1:1,
OPEN.CATEGORY=1001:1:1,CHARGE.CCY=USD:1:1,CHARGE.MKT=1:1:1,INTERES
T.CCY=USD:1:1,INTEREST.MKT=1:1:1,ALT.ACCT.TYPE=LEGACY:1:1,ALLOW.NE
TTING=NO:1:1,SINGLE.LIMIT=Y:1:1,RECORD.STATUS=INAU:1:1,CURR.NO=1:1
:1,INPUTTER=2_OFSUSER1___OFS_TEST.BATCH:1:1,DATE.TIME=0811012041:1
:1,CO.CODE=GB0010001:1:1,DEPT.CODE=1:1:1

| ©2011, Cognizant
OFS Message Syntax – Transaction Response Form

Transaction Message ID Success / Returned


ID / / Fail , Message
Indicator Data

39087//1,CUSTOMER=100724:1:1,CATEGORY=1001:1:1,ACCOUNT.TITLE.1=AAA
SHIPPING COMPANY OF PANAMA:1:1,SHORT.TITLE=AAA SHIPPING COMPANY OF
PANAMA:1:1,POSITION.TYPE=TR:1:1,CURRENCY=USD:1:1,CURRENCY.MARKET=1
:1:1,ACCOUNT.OFFICER=27:1:1,CONDITION.GROUP=2:1:1,PASSBOOK=NO:1:1,
OPEN.CATEGORY=1001:1:1,CHARGE.CCY=USD:1:1,CHARGE.MKT=1:1:1,INTERES
T.CCY=USD:1:1,INTEREST.MKT=1:1:1,ALT.ACCT.TYPE=LEGACY:1:1,ALLOW.NE
TTING=NO:1:1,SINGLE.LIMIT=Y:1:1,RECORD.STATUS=INAU:1:1,CURR.NO=1:1
:1,INPUTTER=2_OFSUSER1___OFS_TEST.BATCH:1:1,DATE.TIME=0811012041:1
:1,CO.CODE=GB0010001:1:1,DEPT.CODE=1:1:1
:1,CO.CODE=GB0010001:1:1,DEPT.CODE=1:1:1`

| ©2011, Cognizant
Transaction response (continued… )

Transaction Message ID Success / Returned


ID / / Fail , Message
Indicator Data

TRANSACTION ID
The transaction ID contains either the value
supplied for the transaction in the request
or the value that is automatically generated
by the TEMENOS T24 application (when no
value is supplied in the request).
MESSAGE ID
The Message ID contains the value of
Message ID if supplied in the request.
| ©2011, Cognizant
Transaction response (continued… )
Transaction Message ID Success / Returned
ID / / Failure , Message
Indicator Data

SUCCESS / FAIL INDICATOR

Indicates the status of the transaction request


processed. OFS returns one of the following
values:
1 Successful transaction.
-1 Errors encountered during processing.
-2 Override condition (s) encountered during processing.
-3 T24 server is offline

| ©2011, Cognizant
Transaction response
• Response – SV
when MV and Returned Message
are supplied Data
in the request:

Field Muliti Sub Field


Name : Value : value =
content
Number number

Field Field Multi Sub


Name = content : value : value
number number

Field Name –The field name is as in the STANDARD.SELECTION record of


the application.
Multi value number –the multi value field number is returned.
Sub value number –the sub value field number is returned.
Field content – the contents of the field

| ©2011, Cognizant
Transaction response – example 1
FUNDS.TRANSFER,,ARCUSER01/654321,,TRANSACTION.
TYPE=AC,DEBIT.ACCT.NO=19038,DEBIT.CURRENCY=EUR
,DEBIT.AMOUNT=1000,CREDIT.ACCT.NO=19089,DEBIT.
VALUE.DATE=20080109
FT080090DL32//1,TRANSACTION.TYPE=AC:1:1,DEBIT.
ACCT.NO=19038:1:1,CURRENCY.MKT.DR=1:1:1,DEBIT.
CURRENCY=EUR:1:1,DEBIT.AMOUNT=1000.00:1:1,DEBI
T.VALUE.DATE=20080109:1:1,CREDIT.ACCT.NO=19089
:1:1,CURRENCY.MKT.CR=1:1:1,CREDIT.CURRENCY=EUR
:1:1,CREDIT.VALUE.DATE=20080109:1:1,PROCESSING
.DATE=20080109:1:1,CHARGE.COM.DISPLAY=NO:1:1,C
OMMISSION.CODE=DEBIT PLUS
CHARGES:1:1,CHARGE.CODE=DEBIT PLUS
10001:1:1,DEBIT.COMP.CODE=GB0010001:1:1,LOC.AM
T.DEBITED=1420.00:1:1,LOC.AMT.CREDITED=1420.00
| ©2011, Cognizant

:1:1,CUST.GROUP.LEVEL=99:1:1,DEBIT.CUSTOMER=10
Transaction response – example
FUNDS.TRANSFER,/R/VALIDATE,AUTHOR/123456,FT080
090DL32

FT080090DL32//1,TRANSACTION.TYPE:1:1=AC,DEBIT.
ACCT.NO:1:1=19038,CURRENCY.MKT.DR:1:1=1,DEBIT.
CURRENCY:1:1=EUR,DEBIT.AMOUNT:1:1=1000.00,DEBI
T.VALUE.DATE:1:1=20080109,CREDIT.ACCT.NO:1:1=1
9089,CURRENCY.MKT.CR:1:1=1,CREDIT.CURRENCY:1:1
=EUR,CREDIT.VALUE.DATE:1:1=20080109,PROCESSING
.DATE:1:1=20080109,COMMISSION.CODE:1:1=DEBIT
PLUS CHARGES,CHARGE.CODE:1:1=DEBIT PLUS

| ©2011, Cognizant
Transaction Response – for incorrect data portion
FUNDS.TRANSFER,/I/VALIDATE,INPUTT/123123,,
TRANSACTION.TYPE=AC,DEBIT.ACCT.NO=10103,
DEBIT.CURRENCY=AUD,DEBIT.AMOUNT=300,CREDIT.ACCT.NO=10138,C
REDIT.CURRENCY=CHF

 Sample message contains debit currency which is NOT


the currency of the account

FT080091P41D//-1/NO,DEBIT.CURRENCY:1:1=DEBIT ACCT CCY NOT


EQ DEBIT CCY

Error message returned in place of Debit Currency value

Sli | ©2011, Cognizant

de
Transaction Response – for incorrect operation
FUNDS.TRANFER,/I/VALIDATE,INPUTT/123123,,
TRANSACTION.TYPE=AC,DEBIT.ACCT.NO=10103,
DEBIT.CURRENCY=CHF,DEBIT.AMOUNT=300,CREDIT.ACCT.NO=10138,C
REDIT.CURRENCY=CHF

 Sample message contains a mis-spelt FUNDS.TRANFER

APPLICATION MISSING

Error message returned


Transaction Response – for incorrect user informat
FUNDS.TRANSFER,/I/PROCESS,INPUTT/12313,,
TRANSACTION.TYPE=AC,DEBIT.ACCT.NO=10103,
DEBIT.CURRENCY=CHF,DEBIT.AMOUNT=300,CREDIT.ACCT.NO=10138,C
REDIT.CURRENCY=CHF

 Sample message contains a wrong password

SECURITY VIOLATION

Error message returned


Enquiry Response - Sample
ENQUIRY.SELECT,,INPUTT/123123,CURRENCY-LIST

,@ID::@ID/NUM.CCY::Ccy/NO.OF.DECIMALS::No Of
Decimals/QUOTATION.CODE::Quotation
Code/DAYS.DELIVERY::Delivery Days/MID.REVAL.RATE::Mid
Reval Date/BUY RATE::Buy Rate/SELL::Sell
Rate/DATE.TIME::Date,"AED" "784" "2 " "
" "1 " " 3.67250" " 3.67300" "
3.67200" "04 DEC 07 10:22","AUD" " 36" "2 " "0
" "1 " " 0.95000" " 0.94000" "
0.96000" "04 APR 08 17:45","CAD" "124" "2 " "
" "1 " " 1.20125" " 1.20150" "
1.20100" "04 DEC 07 10:25","CHF" "756" "2 " "
" "1 " " 1.18600" " 1.19600" "
1.17600" "04 DEC 07 10:25"
Enquiry and output

,@ID::@ID/NUM.CCY::Ccy/NO.OF.DECIMALS::No Of
Decimals/QUOTATION.CODE::Quotation Code/
DAYS.DELIVERY::Delivery Days/MID.REVAL.RATE::Mid Reval
Date/BUY RATE::Buy Rate/SELL::Sell
Rate/DATE.TIME::Date,"AED" "784" "2 " " "
"1 " " 3.67250" " 3.67300" " 3.67200"
"04 DEC 07 10:22","AUD" " 36" "2 " "0 " "1 "
" 0.95000" " 0.94000" " 0.96000" "04 APR
08 17:45","CAD" "124" "2 " " " "1 " "
1.20125" " 1.20150" " 1.20100" "04 DEC 07
10:25","CHF" "756" "2 " " " "1 " "
1.18600" " 1.19600" " 1.17600" "04 DEC 07
10:25"
When are headers shown?

Headers are shown when an


enquiry field contains data
meant to be displayed as a
header
Why? Fixed column position
OFS.SOURCE entries for Telnet Mode

42
Simulating an online connection

Type tSS followed by the OFS.source.id at the jshell prompt


You should get a screen similar to the one shown below

43
Testing Telnet mode (cont…)

Enter the following OFS transaction request


ABBREVIATION,/I/PROCESS,AUTHOR/123123,CUST,ORIGINAL.TEXT=CUSTOM
ER

Response

44
Logs

2 Types
Standard log – like &COMO&
OFS Request Detail
Written by OFS Request Manager
Log Settings

Key fields with sample data


Fields Sample data
Log File Dir LOGDIR
Log Detail FULL
Level
Logging using ORD

Key fields with sample data


Fields Sample data
Maint Msg Dets Y
Det Prefix OL
OFS.REQUEST.DETAIL

User specified

System generated
PPPPPPJJJJJUUUUUTTTTTT.NN
Workshop

Change your batch OFS.SOURCE record to include a log directory called


OFSLOG.
Switch on the log and ORD
Make sure that you put in prefix for your ORD record ids.
Input two messages – one that is correct and one that has a wrong field
value.
Check your log and ORD
Preventing Duplicate messages - Message Ids
Request
FUNDS.TRANSFER,/I/PROCESS,INPUTT/123123,/ABCDEFG10,TRANSA
CTION.TYPE=AC,DEBIT.ACCT.NO=10103,DEBIT.CURRENCY=CHF,DEBI
T.AMOUNT=300,CREDIT.ACCT.NO=10138,CREDIT.CURRENCY=CHF

Slide 50
Preventing Duplicate messages - Attributes
Field
OFS.SOURCE Attributes field
NO.DUPLICATE.CHECK
Checks F.OFS.UNIQUE.MSG.REF
Restricting Access in OFS

For any message through a particular source


OFS.SOURCE - Set the RESTRICT.LINK field to
CLOSE
For an application
PGM.FILE - enter .NOFS in the ADDITIONAL.INFO
field
Restricting Access – PGM.FILE

Request
FUNDS.TRANSFER,TEST.OVERRIDE/I/PROCESS,INPUTT/123123,,TRA
NSACTION.TYPE=AC,DEBIT.ACCT.NO=10014,DEBIT.CURRENCY=AUD,D
EBIT.AMOUNT=19,CREDIT.ACCT.NO=10057

Response
FUNDS.TRANSFER INVALID APPLICATION FOR OFS PROCESSING
Feature 1 -Setting the No of
Authorizers
OFS messages can contain the no of authorisers
Eg. We can use a //0 after PROCESS to indicate zero authoriser.
This overrides the no of authorisers specified in the version ( if a
version is used)

CUSTOMER,/I/PROCESS//0,AUTHOR/123456,,MNEMONIC=AIRFRG,SHO
RT.NAME=AIRBOURNE FREIGHT,NAME.1=AIRBOURNE
FREIGHT,STREET=3101 WESTERN
AVE,TOWN.COUNTRY=SEATTLE,RELATION.CODE:1=1,REL.CUSTOMER:1
=100424,RELATION.CODE:2=2,REL.CUSTOMER:2=100724,SECTOR=20
01,ACCOUNT.OFFICER=1,INDUSTRY=1000,TARGET=999,NATIONALITY
=IN,CUSTOMER.STATUS=1,RESIDENCE=IN,LANGUAGE=1

54
Feature 2 - Changing field values

Null
Removing subvalues
Assigning NULL example
Request
ACCOUNT,/I/PROCESS//0,INPUTT/123123,39087,
ACCOUNT.TITLE.2=NULL

Response
39087//1,CUSTOMER=100724:1:1,CATEGORY=1001:1:1,ACCOUNT.TI
TLE.1=AAA SHIPPING COMPANY OF PANAMA:1:1,SHORT.TITLE=AAA
SHIPPING COMPANY OF
PANAMA:1:1,POSITION.TYPE=TR:1:1,CURRENCY=USD:1:1,CURRENCY
.MARKET=1:1:1,ACCOUNT.OFFICER=27:1:1,CONDITION.GROUP=2:1:
1,CAP.DATE.CHARGE=20080131:1:1,PASSBOOK=NO:1:1,OPENING.DA
TE=20080110:1:1,OPEN.CATEGORY=1001:1:1,CHARGE.CCY=USD:1:1
,CHARGE.MKT=1:1:1,INTEREST.CCY=USD:1:1,INTEREST.MKT=1:1:1
,ALT.ACCT.TYPE=LEGACY:1:1,ALLOW.NETTING=NO:1:1,SINGLE.LIM
IT=Y:1:1,CURR.NO=3:1:1,INPUTTER=11_INPUTTER___OFS_TEST.TE
LNET:1:1,DATE.TIME=0811131421:1:1,AUTHORISER=11_INPUTTER_
OFS_TEST.TELNET:1:1,CO.CODE=GB0010001:1:1,DEPT.CODE=1:1:1
Removing a sub value example
Before
Removing
Request a multi value example
CUSTOMER,/I/PROCESS//0,INPUTT/123123,100424,
RELATION.CODE:2:1=-

Response
100424//1,MNEMONIC:1:1=AFRIBANK,SHORT.NAME:1:1=AFRIBANK,N
AME.1:1:1=AFRIBANK,STRE
ET:1:1=51-52 BROAD STREET,TOWN.COUNTRY:1:1=PMB 12021
LAGOS NIGERIA,
RELATION.CODE:1:1=2,REL.CUSTOMER:1:1=100724,
REVERS.REL.CODE:1:1=12,SECTOR:1:1=3001,ACCOUNT.OF
FICER:1:1=27,INDUSTRY:1:1=3100,TARGET:1:1=999,NATIONALITY
:1:1=NG,CUSTOMER.STATUS:1:1=22,RESIDENCE:1:1=NG,LANGUAGE:
1:1=1, COMPANY.BOOK:1:1=GB0010001,CLS.CPARTY:1:1=NO,
CURR.NO:1:1=3,INPUTTER:1:1=4_INPUTTER___OFS_TEST.TELNET,
DATE.TIME:1:1=0811141247,AUTHORISER:1:1=4_INPUTTER_OFS_TE
ST.TELNET,CO.CODE:1:1=GB0010001,DEPT.CODE:1:1=1
Removing a sub value example
After
Removing a sub value example
After
Special characters in OFS messages

Some OFS messages may contain special characters as part of the data
An address might contain a comma
Eg: 146, Sterling Road
An OFS request to create a version would use
comma as part of the record id
Eg: A version MEMBER of CUSTOMER would have an id
CUSTOMER,MEMBER

Comma in the data portion might convey a completely different meaning

61
Commas in OFS messages - solution

Use ? instead of commas in the data


Questions marks are converted to commas before processing by
the OFS module

Request
ABBREVIATION,/I/PROCESS,INPUTT/123123
,CUF3,ORIGINAL.TEXT=CUSTOMER? I F3

Response
CUF3//1,ORIGINAL.TEXT=CUSTOMER, I
F3:1:1,RECORD.STATUS=INAU:1:1,CURR.NO=
1:1:1,INPUTTER=13_INPUTTER___OFS_TEST.
TELNET:1:1,DATE.TIME=0811111442:1:1,
CO.CODE=GB0010001:1:1,DEPT.CODE=1:1:1
Special Characters in OFS

Character OFS Replacement character


, comma ? Question mark
‘ single quote @
“ double quote | pipeline
() round parenthesis {} curled brackets
/ slash ^ caret
Workshop

Write a OFS transaction request to create a zero authorised version for


ACCOUNT called NEWACCOUNT
Test this out using the OFS online mode

64
Transaction message without
replace
Requestoption
CUSTOMER,/I/PROCESS//0,AUTHOR/123456,100966,REL.CUSTOMER:1
=100172

Response
100966/IM0723600003/1,MNEMONIC:1:1=AIRFRG,SHORT.NAME:1:1=
AIRBOURNE FREIGHT,NAME.1:1:1=AIRBOURNE
FREIGHT,STREET:1:1=3101 WESTERN
AVE,TOWN.COUNTRY:1:1=SEATTLE,RELATION.CODE:1:1=1,RELATION
.CODE:2:1=2,REL.CUSTOMER:1:1=100172,REL.CUSTOMER:2:1=1007
24,REVERS.REL.CODE:1:1=10,REVERS.REL.CODE:2:1=12,SECTOR:1
:1=2001,ACCOUNT.OFFICER:1:1=1,INDUSTRY:1:1=1000,TARGET:1:
1=999,NATIONALITY:1:1=IN,CUSTOMER.STATUS:1:1=1,RESIDENCE:
1:1=IN,LANGUAGE:1:1=1,COMPANY.BOOK:1:1=GB0010001,CLS.CPAR
TY:1:1=NO,OVERRIDE:1:1=INTRO/CUS*100 FROM 100966 NOT
RECEIVED,CURR.NO:1:1=2,
INPUTTER:1:1=15_AUTHORISER___OFS_TAABS,DATE.TIME:1:1=0712
131515,AUTHORISER:1:1=15_AUTHORISER_OFS_TAABS,CO.CODE:1:1
=GB0010001,DEPT.CODE:1:1=1
Note that only the specific multi-value haschanged

65
Transaction Request with
Replace option
CUSTOMER,/I/PROCESS//0,AUTHOR/123456////1,100966,MNEMONIC
=AIRFRG,SHORT.NAME=AIRBOURNE FREIGHT,NAME.1=AIRBOURNE
FREIGHT,STREET=3101 WESTERN
AVE,TOWN.COUNTRY=SEATTLE,RELATION.CODE:1=1,REL.CUSTOMER:1
=100300,SECTOR=2001,ACCOUNT.OFFICER=1,INDUSTRY=1000,TARGE
T=999,NATIONALITY=IN,CUSTOMER.STATUS=1,RESIDENCE=IN,LANGU
AGE=1

USER INFORMATION
Username/password/companycode///1
1 denotes replace option.

66
Transaction Response

100966/IM0723600005/1,MNEMONIC=AIRFRG:1:1,SHORT.NAME=AIRB
OURNE FREIGHT:1:1,NAME.1=AIRBOURNE
FREIGHT:1:1,STREET=3101 WESTERN
AVE:1:1,TOWN.COUNTRY=SEATTLE:1:1,RELATION.CODE=1:1:1,REL.
CUSTOMER=100300:1:1,REVERS.REL.CODE=10:1:1,SECTOR=2001:1:
1,ACCOUNT.OFFICER=1:1:1,INDUSTRY=1000:1:1,TARGET=999:1:1,
NATIONALITY=IN:1:1,CUSTOMER.STATUS=1:1:1,RESIDENCE=IN:1:1
,LANGUAGE=1:1:1,COMPANY.BOOK=GB0010001:1:1,CLS.CPARTY=NO:
1:1,OVERRIDE=INTRO/CUS*100 FROM 100966 NOT
RECEIVED:1:1,CURR.NO=3:1:1,INPUTTER=15_AUTHORISER___OFS_T
AABS:1:1,DATE.TIME=0712131521:1:1,AUTHORISER=15_AUTHORISE
R_OFS_TAABS:1:1,CO.CODE=GB0010001:1:1,DEPT.CODE=1:1:1

Note : The existing multi-valued REL.CUSTOMERs are replaced totally

67
GTS.CONTROL

Controls what should OFS do if faced with an error or override message


Available as a field in VERSION and VERSION.CONTROL
Optional part of request
GTS.CONTROL in Request supersedes that of VERSION &
VERSION.CONTROL
GTS Control values

Value What will OFS do with the transaction?


Null Error - reject record & return error response
Override – approve automatically and commit
1 Error – INAU file with status hold
Override – approve automatically and commit
2 Error - reject record & return error response
Override – INAU file with status hold
3 Error - INAU file with status hold
Override – INAU file with status hold
4 All transactions –write all transactions into INAU
file with status HOLD
GTS.CONTROL in Transaction Request
Operation Options User Transaction Message
, , , ,
Information ID Data

Version/Function/ProcessType/ GTS Control/ No of authorisers

Options
Comprises of VERSION-
NAME/FUNCTION/PROCESS TYPE
/ GTS.CONTROL value/NO.OF.AUTHORISERS.

70
Setting GTS control in the version
Overrides & GTS.CONTROL
Request
FUNDS.TRANSFER,TEST.OVERRIDE/I/PROCESS,INPUTT/123123,,TRA
NSACTION.TYPE=AC,DEBIT.ACCT.NO=22117,DEBIT.CURRENCY=AUD,D
EBIT.AMOUNT=167,CREDIT.ACCT.NO=22179
Response (partial)
FT0801098RH7//1,TRANSACTION.TYPE=AC:1:1,DEBIT.ACCT.NO=221
17:1:1,CURRENCY.MKT.DR=1:1:1,DEBIT.CURRENCY=AUD:1:1,DEBIT
.AMOUNT=167.00:1:1,DEBIT.VALUE.DATE=20080110:1:1,
CREDIT.ACCT.NO=22179:1:1,CURRENCY.MKT.CR=1:1:1,
CREDIT.CURRENCY=AUD:1:1,CREDIT.VALUE.DATE=20080110:1:1,
PROCESSING.DATE=20080110:1:1,CHARGE.COM.DISPLAY=NO:1:1,
STMT.NOS=VAL:1:1,OVERRIDE=ACCT.UNAUTH.OD}Unauthorised
overdraft of & & on
account&.{AUD}167}22117{AUD{167{22117{100777{213{{:1:1,RE
CORD.STATUS=INAU:1:1,CURR.NO=1:1:1,INPUTTER=1_INPUTTER___
OFS_GCS:1:1,DATE.TIME=0811181508:1:1,CO.CODE=GB0
010001:1:1,DEPT.CODE=1:1:1
Setting GTS control in the version
Version & GTS.CONTROL
Request
FUNDS.TRANSFER,TEST.OVERRIDE/I/PROCESS,INPUTT/123123,,TRA
NSACTION.TYPE=AC,DEBIT.ACCT.NO=10057,DEBIT.CURRENCY=AUD,D
EBIT.AMOUNT=11,CREDIT.ACCT.NO=10014

Response
FT080100MB8V//-2/NO,HOLD - OVERRIDE Unauthorised
overdraft of AUD 11 on account 10057.
NAU Processing
Request
FUNDS.TRANSFER,TEST.OVERRIDE/I/PROCESS,INPUTT/123123,
FT0801098RH7,TRANSACTION.TYPE=AC,DEBIT.ACCT.NO=22117,DEBI
T.CURRENCY=AUD,DEBIT.AMOUNT=100,CREDIT.ACCT.NO=22179
Response (partial)
FT0801098RH7//1,TRANSACTION.TYPE=AC:1:1,DEBIT.ACCT.NO=221
17:1:1,CURRENCY.MKT.DR=1:1:1,DEBIT.CURRENCY=AUD:1:1,DEBIT
.AMOUNT=100.00:1:1,DEBIT.VALUE.DATE=20080110:1:1,
CREDIT.ACCT.NO=22179:1:1,CURRENCY.MKT.CR=1:1:1,CREDIT.CUR
RENCY=AUD:1:1,CREDIT.VALUE.DATE=20080110:1:1,STMT.NOS=VAL
:1:1,OVERRIDE=ACCT.UNAUTH.OD}Unauthorised overdraft of &
& on account
&.{AUD}100}22117{AUD{100{22117{100777{213{{:1:1,RECORD.ST
ATUS=INAU:1:1,CURR.NO=1:1:1,INPUTTER=1_INPUTTER___OFS_GCS
:1:1,DATE.TIME=0811181521:1:1,CO.CODE=GB001
0001:1:1,DEPT.CODE=1:1:1
NAU Processing - values

Value Behaviour
0 Applies to input & reversals . Effect - Reject
messages when an NAU record exists
1 Applies to Input only. Effect - Overwrites NAU
record with the values from the OFS message.
2 Applies to Reversals only. Effect - Deletes NAU +
reverses live
3 Applies to input & reversals . Effect - Behaviour
of 1 & 2
NAU Processing example - input
Request
FUNDS.TRANSFER,TEST.OVERRIDE/I/PROCESS,INPUTT/123123,,TRA
NSACTION.TYPE=AC,DEBIT.ACCT.NO=10707,DEBIT.CURRENCY=CHF,D
EBIT.AMOUNT=100,CREDIT.ACCT.NO=22608
Response (partial)
FT08010DRS9M//1,TRANSACTION.TYPE=AC:1:1,DEBIT.ACCT.NO=107
07:1:1,CURRENCY.MKT.DR=1:1:1,DEBIT.CURRENCY=CHF:1:1,DEBIT
.AMOUNT=100.00:1:1,DEBIT.VALUE.DATE=20080110:1:1,CREDIT.A
CCT.NO=22608:1:1,CURRENCY.MKT.CR=1:1:1,CREDIT.CURRENCY=CH
F:1:1,CREDIT.VALUE.DATE=20080110:1:1,PROCESSING.DATE=2008
0110:1:1,CHARGE.COM.DISPLAY=NO:1:1,AMOUNT.DEBITED=CHF100.
00:1:1,AMOUNT.CREDITED=CHF100.00:1:1,CREDIT.COMP.CODE=
GB0010001:1:1,DEBIT.COMP.CODE=GB0010001:1:1,LOC.AMT.DEBIT
ED=84.32:1:1,LOC.AMT.CREDITED=84.32:1:1,,STMT.NOS=VAL:1:1
,RECORD.STATUS=INAU:1:1,CURR.NO=1:1:1,INPUTTER=2_INPUTTER
___OFS_GCS:1:1,DATE.TIME=0811191207:1:1,CO.CODE=GB0010001
:1:1,DEPT.CODE=1:1:1
Let’s try

Change the NAU processing field in the Funds Transfer version to 0


Input a Funds Transfer.
Observe the result
Input the same Funds Transfer again with some changed value
Observe what happens
NAU Processing example – input again
Request
FUNDS.TRANSFER,TEST.OVERRIDE/I/PROCESS,INPUTT/123123,
FT08010DRS9M,TRANSACTION.TYPE=AC,DEBIT.ACCT.NO=10707,
DEBIT.CURRENCY=CHF, DEBIT.AMOUNT=123,CREDIT.ACCT.NO=22608

Response
FT08010DRS9M//-1/NO,@ID:1:1=NAU.PROCESSING = '0', NAU
RECORD CANT BE UPDATED
NAU Processing 1 EXAMPLE
Request
FUNDS.TRANSFER,TEST.OVERRIDE/I/PROCESS,INPUTT/123123,
FT08010DRS9M,TRANSACTION.TYPE=AC,DEBIT.ACCT.NO=10707,
DEBIT.CURRENCY=CHF, DEBIT.AMOUNT=123,CREDIT.ACCT.NO=22608

Response (partial)
FT08010DRS9M//1,TRANSACTION.TYPE=AC:1:1,DEBIT.ACCT.NO=107
07:1:1,CURRENCY.MKT.DR=1:1:1,DEBIT.CURRENCY=CHF:1:1,DEBIT
.AMOUNT=123.00:1:1,DEBIT.VALUE.DATE=20080110:1:1,CREDIT.A
CCT.NO=22608:1:1,CURRENCY.MKT.CR=1:1:1,CREDIT.CURRENCY=CH
F:1:1,CREDIT.VALUE.DATE=20080110:1:1,PROCESSING.DATE=2008
0110:1:1,CHARGE.COM.DISPLAY=NO:1:1,
,STMT.NOS=VAL:1:1,RECORD.STATUS=INAU:1:1,CURR.NO=1:1:1,
INPUTTER=2_INPUTTER___OFS_GCS:1:1,DATE.TIME=0811191551:1:
1,CO.CODE=GB0010001:1:1,DEPT.CODE=1:1:1
More on NAU
processing
This table lists the behaviour if NAU.PROCESSING is
NULL and an attempt is made to input a record which is
already in NAU state
Version record
OFS.SOURCE record
OVERRIDE record
Task 1 – AUTO.OVERRIDES

Create a version for the application FUNDS.TRANSFER

Amend the version for the following requirement :

Using the version input FT transactions in


TELNET mode

All FT transactions with an overdraft amount


greater than10000 should be put on HOLD
status

The above stated validation check should be


processed only when the transaction request
Amend the Version record
What is a Routine request ?

A routine request is used to call a custom built subroutine in the T24


server to do some processing.
The OFS module itself does not do any processing here. OFS just calls the
routine specified in the request.
Some instances where these are used include updating a live file, updating
multiple files and returning a custom response.
Routine request – Message syntax

Custom User Custom


Routine , , Information , , Data
Name

 Custom Routine
 The Custom Routine Name is the name of the subroutine
that must be called by OFS.
 Two parameters – one input , one output
 Must have a PGM.FILE record entry with the TYPE “S”
 Custom Data
 Optional
 Any string that must be passed as an argument to the
custom routine
Routine response – Message syntax
Custom Return
Data

The Custom Return Data is the optional output string the custom
built subroutine may return.
This is actually the final (returned) value of the 2nd argument of
the subroutine (after the call).
Recommended that your subroutine return a meaningful value
Routine type example - the Code

SUBROUTINE T24.ECHO.ROUTINE(Y.REQUEST, Y.RESPONSE)


!***********************************************************************************
! Subroutine to return the string passed thru the Y.REQUEST argument)
! Arguments:
! Y.REQUEST - contains the incoming string
! Y.RESPONSE - contains the echo'ed back string
!***********************************************************************************
!
IF Y.REQUEST NE '' THEN ; * Check for emptiness
Y.RESPONSE = "Received from OFS : " : Y.REQUEST ; * Talk back !
END ELSE
Y.RESPONSE = "Did not receive anything from OFS" ; * Tell ‘em !
END
!
RETURN
!
END
Routine type example - PGM.FILE entry
Routine type example – test message 1

Request
T24.ECHO.ROUTINE,,INPUTT/123123,,Hello T24

Response
Received from OFS : Hello T24
OFS.GLOBUS.MANAGER

Syntax
OFS.GLOBUS.MANAGER(OFS.SOURCE.ID, OFS.MESSAGE)

Parameters
OFS.SOURCE.ID: In parameter. OFS.SOURCE
record id of type GLOBUS
OFS.MESSAGE : In o& out parameter. Passes in the
OFS request and sends back the OFS Response
Other information:
Cannot be called from local API such as versions
from R5
For internal use within core T24 code
Even internally, usage mostly replaced with
Examples of OFS.GLOBUS.MANAGER in use

ROUTINE/APPLICATION Purpose
LC.INWARD To perform additional updates
for inward message types 700,
701, 705, 707
AZ.UNAUTH.PROCESSING Deletes unauthorised AZ , TT &
FT records during COB
AA.PROCESS.CONTRACT Handles OFS processing for AA
OGM– nice to know stuff

In scenarios where OFS.GLOBUS.MANAGER is already loaded in the


session, the request is written into the queue specified in the
OFS.SOURCE record under IN.QUEUE.DIR field
O.G.M may only be used if the write cache is empty
OFS.GLOBUS.MANAGER builds up its own OFS.SOURCE record if the
OFS.SOURCE record id argument is not supplied.
OFS.POST.MESSAGE
Syntax:
OFS.POST.MESSAGE(OFS.MESSAGE, OFS.MSG.ID,
OFS.SOURCE.ID, OPTIONS)

Parameters :
OFS.MESSAGE : In parameter. The OFS
message to be processed
OFS.MSG.ID: Out parameter. Auto generated
message id.
OFS.SOURCE.ID: In parameter. OFS source
record id of type Globus
Options: reserved for future use
Example of OFS.POST.MESSAGE in use

ROUTINE/APPLICATION Purposer
STO.GEN.EXP.RECS Updates the application
AC.EXPECTED.RECS during
authorisation of an STO
FX.CREATE.RECORDS Called when authorising
FX.ORDER. Used for bulk FX .
CR.OPPORTUNITY.PROCESSING Builds PW related records for
CR during COB
OFS.MESSAGE.SERVICE

This is a standard T24 service


It has it’s own workload profile , where the no of agents are
usually set to 1.
Workshop 1 – Code

SUBROUTINE TEST.OFS
$INSERT I_COMMON
$INSERT I_EQUATE
OFS.STR =
'FUNDS.TRANSFER,/I/PROCESS,INPUTT/123123,,TRANSACTION.TYPE=AC,DEBIT.
ACCT.NO=14378,DEBIT.CURRENCY=CHF,DEBIT.AMOUNT=300,CREDIT.ACCT.NO=226
08,CREDIT.CURRENCY=CHF'
OFS.SRC = 'GENERIC.OFS.PROCESS'
OFS.MSG.ID = ''
OPTIONS = ''
CALL OFS.POST.MESSAGE(OFS.STR,OFS.MSG.ID,OFS.SRC,OPTIONS)
CALL JOURNAL.UPDATE("")
RETURN
END
Workshop 1 cont…

PGM.FILE entry for the program


Workshop 1 – Testing if it worked

Run the program from the mainline


View the record created in F.OFS.MESSAGE.QUEUE

149540003123657.00.1-GENERIC.OFS.PROCESS
001
FUNDS.TRANSFER,/I/PROCESS,INPUTT/123123,,TRAN
SACTION.TYPE=AC,DEBIT.ACCT.NO

=14378,DEBIT.CURRENCY=CHF,DEBIT.AMOUNT=300,CR
EDIT.ACCT.NO=22608,CREDIT.CUR
RENCY=CHF
Workshop - Requirement

DEADDRESS is normally updated with Customer address when a new


customer record is authorised
Automate the process of creating a second address in the DE.ADDRESS
file when a Customer record is authorised
Workshop -Algorithm
Check if the customer record being authorized is a new customer
record

Get the value for the second address through a local reference
field.

Form a record for the DE.ADDRESS file with the short name,
name.1, name.2 and street.address. The first 3 fields should
be extracted from the corresponding fields in the customer
record and street.address from the local reference field.

Form the id of the DE.ADDRESS file

Write the record formed into the DE.ADDRESS file using the API
OFS.POST.MESSAGE
Workshop - Algorithm – forming the id of
DE.ADDRESS
DE.ADDRESS records have ids usually created in the following format
company-id.C-customer-id.PRINT.1

We need to create an id in the format


Companycode.C-CustomerNo.PRINT.2
Eg: US0010001.C-100069.PRINT.2

How do we know the current company id?


Use ID.COMPANY
What is ID.COMPANY?
Common variable defined in the I_COMMON file
Holds the id of the current company.
Workshop – Code
SUBROUTINE V.TRG.AUTH.RTN
$INSERT I_COMMON
$INSERT I_EQUATE
$INSERT I_F.CUSTOMER
$INSERT I_F.DE.ADDRESS

GOSUB INIT
GOSUB OPENFILES
GOSUB PROCESS
RETURN

INIT:
FN.CUS = 'F.CUSTOMER'
F.CUS = ''
Y.ADDRESS = ''
RETURN

OPENFILES:
CALL OPF(FN.CUS,F.CUS)
RETURN
Workshop 3 – Code
PROCESS: …
cont
IF R.OLD(1) = '' THEN ;* If it is a new record being authorised

* Form the id of the DE.ADDRESS record

Y.DE.ADDRESS.ID = ID.COMPANY:'.C-':ID.NEW:'.PRINT.2‘
Y.ADDRESS = R.NEW(EB.CUS.LOCAL.REF)<1,7>

Y.OFS.REC=“DE.ADDRESS,,INPUTT/654321,":Y.DE.ADDRESS.ID:",SHORT.NAME
=":R.NEW(EB.CUS.SHORT.NAME):",NAME.1=":R.NEW(EB.CUS.NAME.1):",NAME.
2=":R.NEW(EB.CUS.NAME.2):", STREET.ADDR=":Y.ADDRESS

OFS.MSG.ID=“”
OFS.SOURCE.ID=“TRG.OFS.GLOBUS“
OPTIONS=“”

CALL OFS.POST.MESSAGE (Y.OFS.REC, OFS.MSG.ID, OFS.SOURCE.ID,


OPTIONS)

END

RETURN
END
Workshop

Create and add a local reference field called ADDRESS2 to CUSTOMER


Create a version of the Customer application with all the mandatory fields
and the local ref field ADDRESS2
Compile and catalogue the subroutine and attach it to the Auth.Rtn field
of this version.
Enter a new customer record using the version
Authorise the record
Workshop Testing if it worked …
cont

Check if OFS.MESSAGE.QUEUE has been updated

Start the following services


TSM
OFS.MESSAGE.SERVICE

Check if the message has been removed from F.OFS.MESSAGE.QUEUE

Check if you have the response in F.OFS.RESPONSE.QUEUE


Workshop Testing if it worked

Create and add a local reference field called ADDRESS2 to CUSTOMER


Create a version of the Customer application with all the mandatory fields
and the local ref field ADDRESS2
Compile and catalogue the subroutine and attach it to the Auth.Rtn field
of this version.
Enter a new customer record using the version
Authorise the record
Workshop Testing if it worked …
cont

Check if OFS.MESSAGE.QUEUE has been updated

Start the following services


TSM
OFS.MESSAGE.SERVICE

Check if the message has been removed from F.OFS.MESSAGE.QUEUE

Check if you have the response in F.OFS.RESPONSE.QUEUE


XML Report
XML Report used to produce xml type reports from Enquiry
Report
Normal output is produced if Enquiry Report is not configured for
XML

XML.REPORT,XML,INPUTT/123123,AZ.MATURITY
XML Report- Message Syntax

XML.REPORT Options User Report ID


, , ,
Information

Operation
Must always be XML.REPORT
Options
XML or ID
XML – view xml report directly
ID – get id of output file in &HOLD&
User Information
T24 user information (id, password, company …)
Report Id
Enquiry Report id
112
What do we need to configure

ENQUIRY.REPORT
ENQUIRY
REPORT.CONTROL
DE.FORM.TYPE
PRINTER.ID
A non-hashed file
REPORT.TRANSFORM
Step 1 – Create a form
DE.FORM.TYPE

Printer id is HOLD
Step 2 – Create folders for transformation

Create a UD type file called XML.LOCAL


Create a record within it with an id TRANSLATE.XLS
Step 3 – Point to the folders

Create a record in REPORT.TRANSFORM which points to the


folder and file that you just created
Step 4 – Create a Report Control record

Sample Data
Form Name : XML
Report Transform : XML.TRANSFORM
Xml Trans Context : LOCAL
Step 5 – Create the Enquiry Report
Step 6- Running the Enquiry Report

Verify the Enquiry Report.


A new report will be created and stored in &HOLD&
Get the Report Id from HOLD.CONTROL and view the output
Workshop

Create a XML Report for the Account List

120
Special Transactions

2 in 1 transaction. Input supplied to two different records simultaneously


Can be records within the same application (Eg:
Forex Swap)
Can be one record within one application and
another within related application (eg: LD & LD
Schedule Define/COLLATERAL & COLLATERAL
RIGHT)
We will take a look at FOREX Swap and LD, in detail
Forex Swaps

Forex swap deals involve the exchange of currencies at the spot rate with
an agreement to reverse the transaction with an identical amount of
currency at a later date at a specified rate.
Swap Deal example – 1st leg
Key fields with sample data

Fields Sample data

Deal type SW

Counterparty 100472

Currency bought USD

Amount Bought 3680000

Value Date Buy 20080110

Currency sold GBP

Spot rate 1.84

Transaction type SW
Swap Deal example – 2nd leg
Key fields with sample data

Fields Sample data

Deal type SW

Counterparty 100472

Currency bought GBP

Amount Bought 2000000


(no input)
Value Date Buy 20080121

Currency sold USD

Forward rate 1.86

Transaction type SW
OFS & Forex Swaps – things that matter

Information for both legs supplied within a single message


Information for the first leg is separated from information for the second
leg by an underscore (_).
This applies to the multi value number, sub value number, and field data
parts of the message.
Forex Swap deal sample request

FOREX,/I/PROCESS//0,INPUTT/123123,,DEAL.TYPE=SW,COUNTERPARTY=100472,CU
RRENCY.BOUGHT=USD,AMOUNT.BOUGHT=3680000,CURRENCY.SOLD=GBP,SPOT.RATE=1.
84,DEAL.DATE=20080110,VALUE.DATE.BUY=20080110_10D,FORWARD.RATE=_1.86,N
OTES:1_1="first leg"_"second leg",NOTES:_2=_"second-line"
Forex Swap deal sample response
FX0801000010/OL080100000238170.00/1,DEAL.TYPE:1:1=SW,COUNTERPARTY:1:1=100472,DEALER.DES
K:1:1=00,CURRENCY.MARKET:1:1=1,CURRENCY.BOUGHT:1:1=GBP,AMOUNT.BOUGHT:1:1=2000000.00,VAL
UE.DATE.BUY:1:1=20080121,CURRENCY.SOLD:1:1=USD,AMOUNT.SOLD:1:1=3720000.00,VALUE.DATE.SE
LL:1:1=20080121,SPOT.RATE:1:1=1.84,FORWARD.RATE:1:1=1.86,SWAP.BASE.CCY:1:1=GBP,LIMIT.RE
FERENCE.NO:1:1=1030.01,POSITION.TYPE.BUY:1:1=TR,POSITION.TYPE.SELL:1:1=TR,DEAL.DATE:1:1
=20080110,REVALUATION.TYPE:1:1=IN,SPOT.DATE:1:1=20080110,BASE.CCY:1:1=GBP,SPOT.LCY.AMOU
NT:1:1=3680000.00,SWAP.REF.NO:1:1=FX0801000009,SWAP.REF.NO:2:1=FX0801000010,INT.RATE.BU
Y:1:1=7.322580645161,INT.RATE.SELL:1:1=42.873896800,OUR.ACCOUNT.PAY:1:1=23779,OUR.ACCOU
NT.REC:1:1=15393,DEL.DATE.BUY:1:1=20080121,DEL.AMOUNT.BUY:1:1=2000000.00,DEL.DATE.SELL:
1:1=20080121,DEL.AMOUNT.SELL:1:1=3720000.00,ACTIVITY.CODE:1:1=1010,CONFIRM.SENT:1:1=D20
081204000023817802,BUY.LCY.EQUIV:1:1=-3680000.00, SEL.LCY.EQUIV:1:1=3720000.00,
BUY.DAILY.ACC.L:1:1=793.94,BUY.ACC.TDATE.L:1:1=0.00,BUY.DAILY.ACC.F:1:1=401.24,BUY.ACC.
TDATE.F:1:1=0.00,SEL.DAILY.ACC.L:1:1=4430.30,SEL.ACC.TDATE.L:1:1=0.00,SEL.DAILY.ACC.F:1
:1=4430.30,SEL.ACC.TDATE.F:1:1=0.00,SWIFT.COMMON.REF:1:1=DEMOPX0186IRVT33,CATEGORY.CODE
:1:1=20030,ACCOUNT.OFFICER:1:1=27,FED.FUNDS:1:1=C,SEND.CONFIRMATION:1:1=NORMAL,SEND.PAY
MENT:1:1=NORMAL,SEND.ADVICE:1:1=NORMAL,NOTES:1:1=second leg,NOTES:2:1=second-
line,TOTAL.INT.BOUGHT:1:1=4413.61, TOTAL.INT.SOLD:1:1 =48733.33,
EQUIV.INT.BOUGHT:1:1=8733.33,EQUIV.INT.SOLD:1:1=48733.33,INT.BASIS.BOUGHT:1:1=E,INT.BAS
IS.SOLD:1:1=B,TRANSACTION.TYPE:1:1=SW,NETTING.STATUS:1:1=N,AMORTISE.POSITION:1:1=NO,SWA
P.PL.FWD.POS:1:1=NO,SOD.MAT:1:1=YES,CLS.DEAL:1:1=NO,OVERRIDE:1:1=Spot rate exceeds
tolerance by &}{-5.64%,OVERRIDE:2:1=NO.LINE}NO LINE
ALLOCATED{{{{{100472{{100472.0001000.01{,CURR.NO:1:1=1,INPUTTER:1:1=2_INPUTTER___OFS_TE
ST.TELNET,DATE.TIME:1:1=0812041036,AUTHORISER:1:1=2_INPUTTER_OFS_TEST.TELNET,CO.CODE:1:
1=GB0010001,DEPT.CODE:1:1=1
Loans and Deposits
Key fields with sample data

Fields Sample data

Customer Id 100297

Currency GBP

Amount 2,000,000

Fin Mat Date 9 Jan 2009

Category 21002

Interest Rate 2.34

Define Scheds YES

Example; Mr.Branson deposits 2 million pounds for two years at


an interest rate of 2.34%
Loans and Deposits
Key fields with sample data

Fields Sample data

Customer Id 100297

Currency GBP

Amount 2,000,000

Fin Mat Date 9 Jan 2009

Category 21002

Interest Rate 2.34

Define Scheds YES

Example; Mr.Branson deposits 2 million pounds for two years at


an interest rate of 2.34%
Loans and Deposits Schedule

Key fields with sample data

Fields Sample data

Forward Backward 4
Key
Base Date Key 3

Sch I for Interest


P for Principal
Date for interest and
principal
Amount 2000000
For principal only.
LD request
LD.LOANS.AND.DEPOSITS,LD.THRU.OFS/I/PROCESS,INPUTT/123123,,CUSTOMER.ID
=100297,CURRENCY=GBP,AMOUNT=2000000,FIN.MAT.DATE::=20100111,CATEGORY::
=21002,INTEREST.RATE::=2.34,DEFINE.SCHEDS::=YES//FORWARD.BACKWARD::=4,
BASE.DATE.KEY::=3,CURRENCY:1:1=GBP,SCH.TYPE:1:1:=I,DATE:1:1:=20080710,
CURRENCY:2:1=GBP,SCH.TYPE:2:1:=I,DATE:2:1:=20090110,CURRENCY:3:1=GBP,S
CH.TYPE:3:1:=I,DATE:3:1:=20090710,CURRENCY:4:1=GBP,SCH.TYPE:4:1:=I,DAT
E:4:1:=20100111,CURRENCY:5:1=GBP,SCH.TYPE:5:1:=P,DATE:4:1:=20100111,AM
OUNT:5=2000000
LD Response
LD0801000014/OL080100000261054.00/1,CUSTOMER.ID=100297:1:1,CURRENCY=GBP:1:1,CURRENCY.MA
RKET=1:1:1,AMOUNT=2000000.00:1:1,BUS.DAY.DEFN=GB:1:1,VALUE.DATE=20080110:1:1,FIN.MAT.DA
TE=20100111:1:1,LIMIT.REFERENCE=9900.01:1:1,CATEGORY=21002:1:1,DRAWDOWN.ACCOUNT=11525:1
:1,INT.RATE.TYPE=1:1:1,INTEREST.BASIS=E:1:1,INT.PAYMT.METHOD=1:1:1,INTEREST.RATE=2.34:1
:1,CAPITALISATION=NO:1:1,TOT.INTEREST.AMT=23335.89:1:1,LIQUIDATION.CODE=1:1:1,LIQUIDATI
ON.MODE=AUTOMATIC:1:1,POSITION.TYPE=TR:1:1,DELIVERY.LINK=1:1:1,PRIN.LIQ.ACCT=11525:1:1,
INT.LIQ.ACCT=11525:1:1,CHRG.LIQ.ACCT=11525:1:1,MIS.ACCT.OFFICER=34:1:1,AGREEMENT.DATE=2
0080110:1:1,STATUS.CONTROL=AUTOMATIC:1:1,STATUS=CUR:1:1,DRAWDOWN.ISSUE.PRC=2000000.00:1
:1,DRAWDOWN.NET.AMT=2000000:1:1,ISSUE.PL.AMOUNT=0:1:1,ISSUE.PRICE=100:1:1,ISSUE.ACCRUAL
=NO:1:1,REIMBURSE.PRICE=100:1:1,REIMBURSE.AMOUNT=2000000.00:1:1,REIMBURSE.ACCRUAL=NO:1:
1,FEE.PAY.ACCOUNT=11525:1:1,DRAWDOWN.ENT.DATE=20080110:1:1,AUTO.SCHEDS=NO:1:1,DEFINE.SC
HEDS=YES:1:1,SEND.PAYMENT=NO:1:1,SEND.CONFIRMATION=Y:1:1,YIELD.METHOD=NO:1:1,MATURE.AT.
SOD=YES:1:1,CURRENCY.CODE=GBP:1:1,EXCG.RATE=1.950000000:1:1,SETTLEMENT.MARKET=1:1:1,CON
VERSION.TYPE=MID:1:1,DEFAULTED.VALUE=NO:1:1,DEALER.DESK=00:1:1,NEGATIVE.RATE=NO:1:1,FWD
.PROJ=5:1:1,STMT.NO=VAL:1:1,OVERRIDE=WITHDRAWL.LT.MIN.BAL}WITHDRAWL MAKES A/C BAL LESS
THAN MIN BAL:1:1,OVERRIDE=ACCT.UNAUTH.OD}Unauthorised overdraft of & & on
account .{GBP}3009237.84}11525{GBP{3009237.84{11525{100297{41{{:2:1,RECORD.STATUS=INAU:
1:1,CURR.NO=1:1:1,INPUTTER=2_INPUTTER___OFS_TEST.TELNET:1:1,DATE.TIME=0812041657:1:1,CO
.CODE=GB0010001:1:1,DEPT.CODE=1:1:1//CURRENCY:1:1=GBP,FORWARD.BACKWARD:1:1=4,BASE.DATE.
KEY:1:1=3,SCH.TYPE:1:1=I,SCH.TYPE:2:1=I,SCH.TYPE:3:1=I,SCH.TYPE:4:1=I,SCH.TYPE:5:1=P,DA
TE:1:1=20080710,DATE:2:1=20090110,DATE:3:1=20090710,DATE:4:1=20100111,DATE:5:1=20100111
,AMOUNT:5:1=2000000.00,CYCLED.DATES:1:1=20080710,CYCLED.DATES:2:1=20090110,CYCLED.DATES
:3:1=20090710,CYCLED.DATES:4:1=20100111,CYCLED.DATES:5:1=20100111,OVERRIDE:1:1=LD.NOT.A
.WORKING.DAY}& IS NOT A WORKING DAY
{10/01/2009,RECORD.STATUS:1:1=INAU,CURR.NO:1:1=1,INPUTTER:1:1=2_INPUTTER___OFS_TEST.TEL
NET,DATE.TIME:1:1=0812041657,CO.CODE:1:1=GB0010001,DEPT.CODE:1:1=1
Workshop

Create a Special Transaction type request to INPUT and AUTHORIZE a


FOREX Swap contract.

Create a Special Transaction type request to INPUT a


LOANS.AND.DEPOSITS contract with schedules.

Also see the OFS.REQUEST.DETAILS table for the updates related to your
messages (if any).
OFS Trigger Routines

Where :Trigger routines attached to OFS.SOURCE


Who: Launched by core OFS routines during the life cycle of a message
What: convert or map message format, update local application, populate
queue
Trigger points and trigger routines
• INITIAL.ROUTINE
• IN.MSG.RTN
OFS.ONLINE.MANAGER • OFS.REQUEST.MANAGER
• OUT.MSG.RTN
• CLOSE.ROUTINE

•QUEUE.INIT.RTN
•IN.DIR.RTN
•IN.MSG.RTN
OFS.QUEUE.MANAGER •OFS.REQUEST.MANAGER
•OUT.MSG.RTN
•QUEUE.CLOSE.RTN

• IN.MSG.RTN
OFS.BULK.MANAGER • OFS.REQUEST.MANAGER
• OUT.MSG.RTN

• MSG.PRE.RTN
OFS.REQUEST.MANAGER • MSG.POST.RTN
Important Triggers

IN.MSG.RTN
The routine specified here will be executed just
BEFORE a message is processed by OFS
Converts or maps data from external to OFS format
Common variables not available
Common to batch and telnet modes
OUT.MSG.RTN
The routine specified here will be executed AFTER
each message has been processed but prior to
sending back to it’s origin.
Converts from OFS to external format
Common variables not available
Common to batch and telnet modes
Important Triggers cont…
MSG.PRE.RTN
Called by the OFS.REQUEST.MANAGER just
prior to the message been processed but
after the IN.MSG.RTN
Common variables accessible
Doesn’t allow alteration of message
Used to update local applications
MSG.POST.RTN
Called by the OFS.REQUEST.MANAGER just
AFTER the message been processed but
before the OUT.MSG.RTN
Common variables accessible
Doesn’t allow alteration of message
Used to update local applications
Examples

OFS.SOURCE Trigger type Routine name


SP.STP.OFS IN.DIR.RTN SC.OFS.INWARD.MAPPING
AC.EXPECTED.RECS OUT.MSG RTN STO.UPDATE.AC.EXP.RECS.I
D
OFS.FX.LIM.ORDER OUT.MSG RTN OFS.UPD.FX.ID
Trigger routines - Scenarios

Let us take a closer look at some trigger routines and their need
with the help of a few scenarios

IN.MSG.RTN

MSG.POST.RTN

IN.DIR.RTN
Scenario 1

A third party system is posting messages to T24. It sends messages in


own format. Each message contains a message id, transaction type,
debit account, debit currency, amount, credit account, credit currency.
These details are written in simple comma delimited format into a
sequential file.
You need to convert the message into an OFS format
Solution

We need a place , a folder, where the third party system can put it’s
messages
Solution: Define a OFS.SOURCE record of type BATCH. Define the
IN.QUEUE.DIR where messages can be stored
We need to convert the messages to OFS format
Solution: Write a routine to convert.
Use IN.MSG.RTN
IN.MSG.RTN
Solution – Code to convert – IN.MSG.RTN
SUBROUTINE FT.OFS.CONVERT(Y.REQUEST)
$INSERT I_FT.OTHERS
$INSERT I_F.FUNDS.TRANSFER
APP.NAME = 'FUNDS.TRANSFER'
OFSFUNCT='I'
PROCESS='PROCESS'
OFSVERSION='FUNDS.TRANSFER,'
GTSMODE=''
NO.OF.AUTH=''
TRANSACTION.ID='/':FIELD(Y.REQUEST,",",1)
R.RECORD=''
R.OFS.RECORD='‘
Solution – Code to convert – IN.MSG.RTN cont…

R.RECORD<FT.TRANSACTION.TYPE>=FIELD(Y.REQUEST,",",2)
R.RECORD<FT.DEBIT.ACCT.NO>=FIELD(Y.REQUEST,",",3)
R.RECORD<FT.DEBIT.CURRENCY>=FIELD(Y.REQUEST,",",4)
R.RECORD<FT.DEBIT.AMOUNT>=FIELD(Y.REQUEST,",",5)
R.RECORD<FT.CREDIT.ACCT.NO>=FIELD(Y.REQUEST,",",6)
R.RECORD<FT.CREDIT.CURRENCY>=FIELD(Y.REQUEST,",",7)
CALL
OFS.BUILD.RECORD(APP.NAME,OFSFUNCT,PROCESS,OFSVERSION,GTSMO
DE,NO.OF.AUTH,TRANSACTION.ID,R.RECORD,R.OFS.RECORD)
FT.REQUEST=Y.REQUEST
FT.MSG.ID=FIELD(Y.REQUEST,",",1)
Y.REQUEST=R.OFS.RECORD
END
Scenario-2

The bank also requires that the FT id generated by T24 and the msg id are
stored in a separate CSV file for auditing and tracking.
Solution-2

We need to store the transaction id and message id.


Solution: Write a routine to store the details on a file.
Use MSG.POST.RTN
MSG.POST.RTN

Think about: Why can’t we use MSG.PRE.RTN to


convert? Why can’t we use IN.MSG.RTN for storing
transaction and message details?
Solution – Code to save – MSG.POST.RTN
SUBROUTINE FT.OFS.SAVE(Y.REQUEST)
$INSERT I_COMMON
$INSERT I_EQUATE
$INSERT I_F.FUNDS.TRANSFER
$INSERT I_FT.OTHERS

GOSUB INIT
GOSUB WRITE.DETAILS
CLOSESEQ F.BP
RETURN

INIT:
Y.RECORD=''
OPENSEQ "TRGOUT","MSGDETAILS.txt" TO F.BP ELSE
CREATE F.BP ELSE ETEXT = "Unable to write to file"
END
RETURN
Solution – Code to save – MSG.POST.RTN cont…
WRITE.DETAILS:
Y.RECORD= ID.NEW:",":FT.MSG.ID
WRITESEQ Y.RECORD TO F.BP ELSE
ETEXT= "Unable to write transaction details"
END

RETURN
Solution – OFS.SOURCE record
Solution – EB.PHANTOM record
Thank you

© 2007, Cognizant Technology Solutions Confidential

You might also like