Conventions

This page describes the conventions used by the PSD2 Services API.

Authentication

Access to resources made available by the API requires authentication. For all requests, an Authorization header must be included, its value containing the authorization type (Bearer), followed by a space, and the API key issued to the partner.

HTTP Verbs

The following table identifies HTTP verbs used, and the type of operations they are used for:

Verb Operation Type

GET

Retrieve a full or partial representation of a resource or resources.

POST

Create a new resource or resources.

Status Codes

The following tables identifies the HTTP status codes used, and the circumstances in which they are used:

Code Circumstance

200

The request was processed successfully; the response body includes a message.

201

The request was processed successfully; the response contains the identifier of a newly created resource.

400

The request has a malformed syntax; the response body may include diagnostic information.

498

The request failed; the response body contains more information.

499

The request failed; the response body contains more information.

500

The request could not be processed; an unexpected error occurred.

For particular resources and operations, additional status codes and circumstances will be identified. Further information will be included within the operation definition.

Message Body Serialization

Request and response bodies are serialized as JSON objects, arrays or simple types. Bodies are encoded using UTF-8.

The Content-Type header must be included in all requests. Its value must be application/json.

Value Types

The following table identifies the different value types used and:

  • The labels used to refer to them in resource documentation

  • The JSON types used to represent them

  • How values are encoded

Property Type Label JSON Type Value Encoding

Boolean

boolean

true / false

-

Byte Array

byteArray

string

The array content is encoded using Base 64.

Double

double

number

-

GUID

guid

string

Using the UUID URN format.

String

string

string

-

Timestamp

timestamp

string

Using ISO-8601.