🔍Overview
G2P Connect API Specifications is an open source effort to standardise the key integrations across functional categories defined in G2P Connect Technology Architecture Blueprint.
G2P Connect Integration Specification assumes interactions between vaious DPI soultion providers (i.e DPGs, Proprietary/Existing systems) may vary due to country specific policies and availability of digital/banking/last mile connectivity infrastructure. For e.g.,\
a. Few countries may have centralised payment switch operated by central bank while others may operate directly with financial institutions. b. Countries may decide to manage ID to Financial Address mapping either at Payment Switch layer or Financial Institution(s) or Beneficiary Management Platforms or an independent entity. c. Countries may not have a foundational de-duplicated digital id.
G2P Connect is flexible to enable DPI solution providers (i.e DPGs, Proprietary/Existing systems) to orchestrate flows based on various use case scenarios that are specific to country's operating requirements.
Objectives
The following are key objectives of G2P Connect Specifications:
Focus on G2P Connect solution blueprint - enable seamless integration between solutions relevant to end to end G2P payment scope keeping policy maker and beneficairy at the center.
Flexible to accomodate existing standards where applicable, e.g., OAuth2, OpenID Connect, W3C Verifiable Crendentialing.
Standardise message envelope to support harmonised integrations across various solutions with key features:
Transport layer agnositc communication
Async based processing with retry/polling support
Offline processing capability enabling store & forward
Batch processing
Support plug n play for other payloads e.g. OpenID / country specific custom data or verifiable credentials
Support for digitally signed and encrypted payloads
Enable integration between existing proprietary, DPI/DPGs or country specific custom in-house solutions.
Focus is on standradising core interfaces and NOT on implementation.
Each interface act as a connector between solutions and allow country implementations to realize various use cases.
Message Structure
All communications using G2P Connect specifications have following structure:
signature
element holding signature to prove non-repudiability of payload (header & message) between sender & receiver
header
common header to track messages between sender & receiver for traceability and to track message delivery at transport layer
message
message to hold transaction request/response entities
Identifiers
message_id: scope of message_id in header is to track paylaod delivery between sender and receiver.
transaction_id: scope of transaction_id in message is to uniquely corelate business request(s).
reference_id: scope of the reference_id in message domain entity is to corelate individual business request.
Normative Addressing
To enable payment processing using various store of value accounts, G2P Connect uses normative addressing format and refer these as financial addresses (fa). e.g. payer fa, payee fa etc.,
To enable integration with various identity systems/registries all beneficiary id's are also represented in normative formats.
Transport Protocol
G2P Connect Integration Specification is designed to be transport layer agnostic viz. JSON entities over HTTPS, pub/sub event based messaging or file exchanges.
header field helps in reliable exchange at transport layer between sender and receiver.
Communication Protocol
Most of the interactions are asynchronous in nature between sender/receiver.
Sender initiates with message_id and receiver synchronously acknowledge with receipt of the message with ACK/NACK/ERR status codes.
ACK represent async callback, NACK represent end of exchange and ERR represent message couldn't be successfully parsed for processing.
For all async /xxxx service end points, Senders are required to implement /on_xxxx end points to receive callback responses.
All services implement /{service}/txn/status and /{service}/txn/on_status end points to poll and fetch repsones of previously attempted requests using transaction_id or reeference_id
For service end points that are exposed to end user interfacing UX channels where call back processing becomes challenging or technical not-feasibile, receiver systems are required to implement GET status api's. Sender systems may poll to GET transaction status/detailed information and limit count of individual business requests (i.e reference_id's).
File based processing
For file based exchange it is recommended to use the JSON payloads. JSON format is hierarchal, self describing for easy integrations.
If a country has use case to use other formats (e.g. CSV) then it is recommended to use the same JSON definitions by flattening each entity as a file row. In this scenario, signature element shall be part of the first row, header elements in second row followed by one or more message array listed in each row. nested objects are to be flatted in the same row.
Above logic shall work for encrypted request element as well.
File exchange may happen using HTTPS, sFTP or any other file exchange mechanisms.
Event based processing
G2P Connect JSON based request/response entities shall work as events over messaging infrastructure.
Trusted sender and receiver systems on a network should create pub/sub end points.
Data Formats
All dates and timestamps are represented in RFC3339 format including timezone e.g., 2022-12-04T18:01:07+05:30
All currency codes represented in ISO 4217 format
Last updated