Developers

Sort Code Lookup

Important note.

All BankVal web services are available on both the main and backup servers at our primary data centre. This configuration is mirrored at our secondary data centre. The two data centres are geographically independent. Using this configuration, the BankVal web service has been available continuously since launch in 2003.

In general:

  • Call the service at the primary data centre at www.unifiedservices.co.uk
  • In the unlikely event of a failure, call the service at the secondary data centre at www.unifiedsoftware.co.uk

1 Sort Code Lookup - REST


Sort Code Lookup Functionality:

  • Retrieves detailed bank branch information for a given sort code using the latest VocaLink Extended Industry Sorting Code Directory, EISCD.

To make sure you utilise our backup system, follow these three steps:-

  • 1. Attempt to access the service on unifiedservices.co.uk
  • 2. Check the http response code
  • 3. If this is < 200 or > 399, access the backup service on unifiedsoftware.co.uk

URI for Sort Code Lookup

  • GET https://www.unifiedservices.co.uk/services/bankvaluk/branchdets2/userid/<userid>/pin/<pin>/sortcode/
    <sortcode>
    /<format>/
  • If http response code is < 200 or > 399 then call:-
  • GET https://www.unifiedsoftware.co.uk/services/bankvaluk/branchdets2/userid/<userid>/pin/<pin>/sortcode/
    <sortcode>
    /<format>/

where:

  • <userid> and <pin> are your user ID and 5 digit PIN obtained upon registration at:
    www.unifiedsoftware.co.uk/free-trial/free-trial-home.html
  • <sortcode> > is the sort code of the bank branch to be queried
  • <format> specifies the format of the returned data. Valid formats are csv, xml and json. (csv uses the "|" delimiter)

Results

If sort code is valid:-

  • First field - contains word VALID
  • Remaining fields - contain data from EISCD, see EISCD file specification

Example Valid Results

Sample valid response in xml format :-

<branchdets>

  • <result>VALID<result>
  • <sortcode>205942</sortcode>
  • <bicbank>BARCGB21</bicbank>
  • <bicbranch>08J</bicbranch>
  • etc...

</branchdets>


Sample valid response in json format :-

  • {"result":"VALID",
  • "sortcode":"205942",
  • "bicbank":"BARCGB21",
  • "bicbranch":"08J",
  • etc...
  • }

Sample valid response in csv format :-

  • |VALID|205942|BARCGB21|08J| etc... |

If sort code and account number are not valid or if an error occurs:-

  • First field - contains error message
  • xml, json - remaining fields are empty
  • csv - no other fields returned

Error messages :-

Error Messages

INVALID - Sortcode - The supplied sort code does not exist in the VocaLink Extended Industry Sorting Code Directory (EISCD).

INVALID - Account - The supplied account number is not in any of the recognisable formats, i.e. 7 - 10 numeric characters in length.

INVALID - Modulus Check Failed - The sort code/ account number combination did not pass the modulus checks specified by the owning bank.

INVALID - Result Format - Problem, with format field in URI.

ERROR - Invalid User ID/PIN - The User ID or PIN has not been recognised.

ERROR - UserID Expired - Trial user ID has expired.

ERROR - Insecure Connection - An attempt was made to access BankVal's getbranchdetails2 method using insecure HTTP protocol instead of HTTPS.


<< Back to Top >>


2 Sort Code Lookup - SOAP


Sort Code Lookup functionality:

  • Retrieves detailed bank branch information for a given sort code using the latest VocaLink Extended Industry Sorting Code Directory, EISCD.

Choose SOAP style:

There are two main ways of implementing SOAP, Document Literal and RPC. For help choosing the best solution for your implementation, please contact support@unifiedsoftware.co.uk.



<< Back to Top >>


2.1 Sort Code Lookup - SOAP Document Literal


Sort Code Lookup functionality:

  • Retrieves detailed bank branch information for a given sort code using the latest VocaLink Extended Industry Sorting Code Directory, EISCD.

WSDL files

The WSDL file on the primary data centre is at https://www.unifiedservices.co.uk/services/bankvaluk/getbranchdetails2.php?wsdl

The WSDL file on the backup data centre is at https://www.unifiedsoftware.co.uk/services/bankvaluk/getbranchdetails2.php?wsdl


Request

Parameters

Description

userid

BankVal UK User ID.

pin

5 digit PIN.

sortcode

Sort code to be validated.


Response

For further information about this data please contact our helpful business advisors at support@unifiedsoftware.co.uk

Field

Description

result

Result string contains on of the following messages:-
VALID - All checks on sort code passed successfully.
INVALID Sortcode - The supplied sort code does not exist in the VocaLink Extended Industry Sorting Code Directory (EISCD).
ERROR - Invalid User ID/PIN - The User ID or PIN has not been recognised.
ERROR - User ID Expired - Trial user ID has expired.
ERROR - Insecure Connection - An attempt was made to access BankVal's getbranchdetails2 method using insecure HTTP protocol instead of HTTPS.

sortcode

Sort code

bicbank

SWIFT Bank Identifier Code for bank

bicbranch

SWIFT code for branch

subbranchsuffix

Main / sub-branch indicator

bankname

Branch title

owningbank

Name of owning bank (short)

longbank1

Full name of owning bank line 1

longbank2

Full name of owning bank line 2

ownbc

Bank code of owning bank

ccode

Central bank country code

supervisorybody

Supervisory body

deletedate

Branch deletion date

changedate

Date of last change

printindicator

Print indicator

bacsstatus

Bacs status

bacschangedate

Date of last change to Bacs clearing data

bacsclosedate

Date of closure in Bacs clearing

bacsredirectfrom

Redirection from flag

bacsredtoscode

Redirected to sort code

bacssettbank

Bacs settlement bank

bacssettsec

Bacs settlement section

bacssettsubsec

Bacs settlement sub-section

bacshandbank

Handling bank

bacshandst

Handling bank stream

bacsaccnumflg

Account numbered flag

bacsddiflg

DDI Voucher flag

bacsdrdisallowed

Transactions disallowed DR (Direct Debits)

bacscrdisallowed

Transactions disallowed CR (Bacs Credits)

bacscudisallowed

Transactions disallowed CU (Claims for unpaid cheques)

bacsprdisallowed

Transactions disallowed PR (Not used)

bacsbsdisallowed

Transactions disallowed BS (Building Society Credits)

bacsdvdisallowed

Transactions disallowed DV (Dividend Interest Payments)

bacsaudisallowed

Transactions disallowed AU (AUDDISS Direct Debit Instructions)

spare1

spare2

spare3

spare4

chapsretind

CHAPS sterling return indicator

chapsstatus

Chaps sterling status

chapsschangedate

Date of last change to CHAPS sterling data

chapssclosedate

Date closed for CHAPS sterling clearing

chapssettmem

CHAPS sterling settlement member

chapssrbicbank

SWIFT bank code for CHAPS sterling routing

chapssrbicbr

SWIFT branch code for CHAPS sterling routing

chapsestatus

CHAPS Euro status

chapsechangedate

Date of last change to CHAPS euro data

chapseclosedate

Date closed for CHAPS euro clearing

chapserbicbank

SWIFT bank code for CHAPS euro clearing

chapserbicbr

SWIFT branch code for CHAPS euro clearing

chapsesettmem

CHAPS euro settlement member

chapseretind

Return indicator

chapseswift

SWIFT data

spare5

ccccstatus

Cheque and Credit Clearing Company status

ccccchangedate

Date of last change to CCCC data

ccccclosedate

Date closed for CCCC clearing

ccccsettbank

CCCC settlement bank

ccccdasc

Debit agency sort code

ccccretind

Return indicator

ccccgbni

GB / Northern Ireland indicator

fpsstatus

Faster Payment System status

fpschangedate

Date of last change to FPS data

fpsclosedate

Closure date for FPS clearing

fpsredirectfrom

Redirection from flag

fpsredirecttosc

Redirection to sort code

fpssettbankct

Connection type

fpsspare1

fpssettbankbc

Bank code of settlement bank

fpssettbankct

Handling bank connection type

fpsspare2

fpshandbankbc

Handling bank code

fpsaccnumflag

Accounts numbered flag

fpsagencytype

FPS agency type

fpsspare3

printbti

Branch type indicator

printmainsc

Sort code of main branch

printmajlocname

Major location name

printminlocname

Minor location name

printbranchname

Branch name or place

printsecentryind

Secondary entry indicator

printsecbrname

Branch name for secondary entry

printfbrtit1

Full branch title - part 1

printfbrtit2

Full branch title - part 2

printfbrtit3

Full branch title - part 3

printaddr1

Address line 1

printaddr2

Address line 2

printaddr3

Address line 3

printaddr4

Address line 4

printtown

Town

printcounty

Country

printpcode1

Major post code

printpcode2

Minor post code

printtelarea

Telephone area 1

printtelno

Telephone number 1

printtelarea2

Telephone area 2

printtelno2

Telephone number 2



<< Back to Top >>


2.1 Sort Code Lookup - SOAP RPC


Sort Code Lookup Functionality:

  • Retrieves detailed bank branch information for a given sort code using the latest VocaLink Extended Industry Sorting Code Directory, EISCD.

Parameter Format for GetBranchDetails2

ReturnMessage = getbranchdetails2(QueryString)

where :

QueryString is a " | " delimited string of the format - "userid|PIN|sort code"

ReturnMessage is a " | " delimited string or an error message, as shown below.

ReturnMessage Meaning

Branch information - This is returned as a " | " delimited character string with a " | " terminating character. See the EISCD file specification for a detailed record layout of the returned branch information.

INVALID - Sortcode - The supplied sort code does not exist in the VocaLink Extended Industry Sorting Code Directory (EISCD).

ERROR - Invalid User ID/PIN - The User ID or PIN has not been recognised.

ERROR - UserID Expired - Trial user ID has expired.

ERROR - Insecure Connection - An attempt was made to access BankVal's getbranchdetails2 method using the insecure HTTP protocol instead of HTTPS.


WSDL files

The WSDL file on the primary data centre is at https://www.unifiedservices.co.uk/bankvaluk3.wsdl

The WSDL file on the backup data centre is at https://www.unifiedsoftware.co.uk/bankvaluk3.wsdl


<< Back to Top >>