# Get UK bank branch info Get information for a United Kingdom (UK) bank-branch given its *sort code* in the path. To read about Pismo's banking offerings, see [Banking overview](doc:banking-overview). In UK banking, a sort code is a unique identification code used to route money transfers between banks and financial institutions. Its similar to a routing number in the US. It is a six-digit number that identifies both the bank and the specific branch. Each bank and branch has its own unique sort code. The first two digits identity the bank and the remaining 4 digits identify the branch. # OpenAPI definition ```json { "openapi": "3.1.0", "info": { "title": "Banking - Bank accounts", "version": "1.0.0", "description": "API for managing bank accounts in global formats", "contact": { "name": "API Support", "url": "https://developers.pismo.io/support/" }, "license": { "name": "Copyright Pismo" } }, "servers": [ { "url": "https://sandbox.pismolabs.io/intl-bankaccounts", "description": "Sandbox API server for testing" } ], "security": [ { "BearerAuth": [] } ], "tags": [ { "name": "Bank accounts", "description": "Bank account management endpoints" } ], "components": { "securitySchemes": { "BearerAuth": { "type": "http", "scheme": "bearer", "description": "Account token - token encoded with Pismo account ID. Tokens can expire quickly, which can result in an **401 Unauthorized** error.", "bearerFormat": "JWT" } }, "parameters": { "auth": { "name": "AuthorizationHeader", "in": "header", "description": "Account token - Token encoded with a Pismo account ID. Tokens can expire quickly, which can result in a **401 Unauthorized** error. \n", "required": true, "schema": { "type": "string" }, "example": 1234 }, "sortCodePath": { "in": "path", "name": "sortCode", "description": "Sort code - used to identify a UK bank-branch. The UK brank branch sort code is a six-digit code that is split into pairs with dashes in between.", "required": true, "schema": { "type": "string" }, "example": "12-34-56" } }, "schemas": { "domain.Error": { "type": "object", "properties": { "code": { "type": "string", "description": "Error type code", "example": "EIBA0001" }, "details": { "type": "string", "description": "Error details", "example": "Key not found" }, "message": { "type": "string", "description": "Error message", "example": "Key not found" } } }, "sortCode": { "type": "string", "description": "In UK banking, a sort code is a unique identifier used to route money transfers between banks and financial institutions. Similar to a routing number in the US. It is a six-digit number that identifies both the bank and the specific branch office. Each bank branch office has its own unique sort code. The first two digits identity the bank and the remaining 4 digits identify the branch.\n", "maxLength": 6, "minLength": 6, "example": "123456" }, "sortcodes.GetSortCodeResponse": { "type": "object", "properties": { "address_line_1": { "type": "string", "description": "Bank office address line 1.", "example": "Bolton Customer Service Centre", "maxLength": 35, "minLength": 0 }, "address_line_2": { "type": "string", "description": "Bank office address line 2.", "example": "PO Box 2027 Parklands", "maxLength": 35, "minLength": 0 }, "address_line_3": { "type": "string", "description": "Bank office address line 3.", "example": "De Havilland Way", "maxLength": 35, "minLength": 0 }, "address_line_4": { "type": "string", "description": "Bank office address line 4.", "maxLength": 35, "minLength": 0, "example": "Horwich" }, "bank_full_name": { "type": "string", "description": "Bankers' Automated Clearing Services (BACS) approved name.", "maxLength": 71, "minLength": 1, "example": "NATIONAL WESTMINSTER BANK PLC" }, "bank_short_name": { "type": "string", "description": "Bankers' Automated Clearing Services (BACS) approved short name.", "maxLength": 20, "minLength": 1, "example": "NAT WEST BANK PLC" }, "city": { "type": "string", "description": "Bank office's town/city.", "maxLength": 30, "minLength": 0, "example": "Bolton" }, "payment_schemes": { "$ref": "#/components/schemas/sortcodes.PaymentSchemes" }, "sort_code": { "$ref": "#/components/schemas/sortCode" }, "zip_code": { "type": "string", "description": "Bank office's postal code.", "maxLength": 9, "minLength": 0, "example": "BL6 BL6" } } }, "sortcodes.PaymentSchemes": { "type": "object", "properties": { "bacs": { "type": "boolean", "description": "Does the bank/branch participate in the Banker's Automated Clearing Service (BACS) payment system?\n", "example": true }, "chaps": { "type": "boolean", "description": "Does the bank/branch participate in the Clearing House Automated Payment System (CHAPS)?\n", "example": true }, "fps": { "type": "boolean", "description": "Does the bank/branch participate in the Faster Payment System (FPS)?\n", "example": true }, "ics": { "type": "boolean", "description": "Does the bank/branch participate in the Image Clearing System (ICS) used for processing cheques in the UK?\n", "example": true } } } } }, "paths": { "/v1/sortcodes/{sortCode}": { "get": { "summary": "Get UK bank branch info", "description": "Get information for a United Kingdom (UK) bank-branch given its *sort code* in the path.\n\nTo read about Pismo's banking offerings, see [Banking overview](https://developers.pismo.io/pismo-docs/docs/banking-overview).\n\nIn UK banking, a sort code is a unique identification code used to route money transfers between banks and financial institutions. Its similar to a routing number in the US. It is a six-digit number that identifies both the bank and the specific branch. Each bank and branch has its own unique sort code. The first two digits identity the bank and the remaining 4 digits identify the branch.\n", "operationId": "get-intl-bank-accounts-v1-sort-codes-sort-code", "tags": [ "Bank accounts" ], "parameters": [ { "$ref": "#/components/parameters/auth" }, { "$ref": "#/components/parameters/sortCodePath" } ], "responses": { "200": { "description": "Get UK bank-branch office info response", "headers": { "x-cid": { "description": "Request tracking identifier.", "schema": { "type": "string" } } }, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/sortcodes.GetSortCodeResponse" } } } }, "400": { "description": "Bad", "headers": { "x-cid": { "description": "Request tracking identifier.", "schema": { "type": "string" } } }, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/domain.Error" }, "examples": { "EIBA0031": { "summary": "Invalid Sort Code", "value": { "code": "EIBA0005", "message": "Invalid sort code path parameter, expected 6-digit number" } } } } } }, "403": { "description": "Forbidden", "headers": { "x-cid": { "description": "Request tracking identifier.", "schema": { "type": "string" } } }, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/domain.Error" } } } }, "404": { "description": "Not Found", "headers": { "x-cid": { "description": "Request tracking identifier.", "schema": { "type": "string" } } }, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/domain.Error" }, "examples": { "EIBA0031": { "summary": "Sort Code Not Found", "value": { "code": "EIBA0005", "message": "Sort Code not found" } } } } } }, "500": { "description": "Internal Server", "headers": { "x-cid": { "description": "Request tracking identifier.", "schema": { "type": "string" } } }, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/domain.Error" }, "examples": { "EIBA0005": { "summary": "HTTP error", "value": { "code": "EIBA0005", "message": "HTTP error" } }, "EIBA0011": { "summary": "Accounts API server error", "value": { "code": "EIBA0011", "message": "Accounts - API returned 5xx error" } }, "EIBA0015": { "summary": "Database error", "value": { "code": "EIBA0015", "message": "Database internal error" } } } } } } } } } } } ```