Download OpenAPI specification:Download
The Social Registry interoperability APIs describes different APIs some of them are usecase specific and other are generalized APIs to perform interoperable operations between social registry and SPMIS. You can now help us improve the API whether it's by making changes to the definition itself or to the code. That way, with time, we can improve the API in general, and expose some of the new features in upcoming version.
Gitbook reference link :
Code directory links:
Data Objects:
Each request is build up of three parts
Information about each part is given below
Signature:
Header:
Message:
The async search api will accept request and will send response to on-search endpoint. The SR will implement /registry/search endpoint and the SPMIS shall implement /registry/on-search to receive data from SR. The search request message consist of reg_event_type, query_type, query, sort, pagination, consent, authorize, locale. The SR will validate the request and will send response to on-search endpoint. Information for each field is given below.
signature | string (MsgSignature) Signature of {header}+{message} body verified using sender's signing public key |
required | object Message header |
required | SearchRequest (object) or EncryptedMessage (object) The search data using which registry search to be performed |
{- "signature": "Signature: namespace=\"spdci\", kidId=\"{sender_id}|{unique_key_id}|{algorithm}\", algorithm=\"ed25519\", created=\"1606970629\", expires=\"1607030629\", headers=\"(created) (expires) digest\", signature=\"Base64(signing content)",
- "header": {
- "version": "1.0.0",
- "message_id": "123",
- "message_ts": "",
- "action": "search",
- "sender_id": "spmis.example.org",
- "receiver_id": "social.example.org",
- "total_count": 21800,
- "is_msg_encrypted": false,
- "meta": { }
}, - "message": {
- "transaction_id": 123456789,
- "search_request": [
- {
- "reference_id": "12345678901234567890",
- "timestamp": "",
- "search_criteria": {
- "version": "1.0.0",
- "reg_event_type": "REGISTER",
- "query_type": "expression",
- "response_entity": "Group",
- "query": {
- "type": "ns:org:QueryType:NoSql",
- "value": {
- "expression": {
- "collection": "Group",
- "query": {
- "$and": [
- {
- "poverty_score": {
- "$lt": 5
}
}, - {
- "location": {
- "$eq": "central_region"
}
}, - {
- "group_size": {
- "$lt": 5
}
}
]
}
}
}
}, - "sort": [
- {
- "attribute_name": "poverty_score",
- "sort_order": "asc"
}
], - "pagination": {
- "page_size": 2000,
- "page_number": 5
}, - "consent": {
- "@type": "Consent",
- "ts": {
- "$ref": "#/components/schemas/MsgHeader_V1.0.0/properties/message_ts"
}, - "purpose": {
- "text": {
- "type": "string"
}, - "code": {
- "type": "string",
- "description": "From a fixed set, documented at refUri"
}, - "ref_uri": {
- "type": "string",
- "format": "uri",
- "description": "Uri to provide more info on consent codes"
}
}
}, - "authorize": {
- "@type": "Authorize",
- "ts": {
- "$ref": "#/components/schemas/MsgHeader_V1.0.0/properties/message_ts"
}, - "purpose": {
- "text": {
- "type": "string"
}, - "code": {
- "type": "string",
- "description": "From a fixed set, documented at refUri"
}, - "ref_uri": {
- "type": "string",
- "format": "uri",
- "description": "Uri to provide more info on authorize codes"
}
}
}
}, - "locale": "en"
}
]
}
}
{- "errors": [
- {
- "code": "string",
- "message": "string"
}
]
}
The /registry/on-search end point tobe implemented by SPMIS to receive search results from SR. The SR will send data in format explained in SearchResponse.yaml. The reg_records will containe data that in explained in social/v1/Person.jsonld. Refer example json at gitbook link.
signature | string (MsgSignature) Signature of {header}+{message} body verified using sender's signing public key |
required | object Message header |
SearchResponse (object) or EncryptedMessage (object) |
{- "signature": "Signature: namespace=\"spdci\", kidId=\"{sender_id}|{unique_key_id}|{algorithm}\", algorithm=\"ed25519\", created=\"1606970629\", expires=\"1607030629\", headers=\"(created) (expires) digest\", signature=\"Base64(signing content)",
- "header": {
- "version": "1.0.0",
- "message_id": "789",
- "message_ts": "",
- "action": "on-search",
- "status": "rcvd",
- "status_reason_code": "rjct.version.invalid",
- "status_reason_message": "string",
- "total_count": 21800,
- "completed_count": 50,
- "sender_id": "social.example.org",
- "receiver_id": "spmis.example.org",
- "is_msg_encrypted": false,
- "meta": { }
}, - "message": {
- "transaction_id": 123456789,
- "correlation_id": "9876543210",
- "search_response": [
- {
- "reference_id": "12345678901234567890",
- "timestamp": "",
- "status": "rcvd",
- "status_reason_code": "rjct.reference_id.invalid",
- "status_reason_message": "string",
- "data": {
- "version": "1.0.0",
- "reg_records": [
- {
- "@context": {
}, - "@type": "spdci:Group",
- "group_identifier": [
- {
- "@type": "Identifier",
- "identifier_type": "NationalID",
- "identifier_value": "G9876543210"
}
], - "group_type": "family",
- "place": {
- "@type": "Place",
- "geo": {
- "@type": "GeoCoordinates",
- "latitude": "40.712776",
- "longitude": "-74.005974"
}, - "address": "123 Main St, Anytown, CountryName"
}, - "place_address": 1,
- "poverty_score": 45.2,
- "poverty_score_type": "income-based",
- "group_head_info": {
- "@type": "spdci:Member",
- "member_identifier": [
- {
- "@type": "Identifier",
- "identifier_type": "NationalID",
- "identifier_value": "M9876543210"
}
], - "demographic_info": {
- "@type": "SRPerson",
- "identifier": [
- {
- "@type": "Identifier",
- "identifier_type": "NationalID",
- "identifier_value": "9876543210"
}
], - "name": {
- "@type": "Name",
- "surname": "Smith",
- "given_name": "Alice",
- "prefix": "Ms.",
- "suffix": ""
}, - "sex": "female",
- "address": {
- "@type": "Address",
- "street_address": "123 Main St",
- "city": "Anytown",
- "postal_code": "12345",
- "country": "CountryName"
}, - "birth_date": "1985-05-20T00:00:00Z",
- "registration_date": "2022-01-10T08:00:00Z"
}, - "is_disabled": false,
- "marital_status": "married",
- "registration_date": "2022-01-10T08:00:00Z"
}, - "group_size": 4,
- "member_list": [
- {
- "@type": "Member",
- "member_identifier": [
- {
- "@type": "Identifier",
- "identifier_type": "NationalID",
- "identifier_value": "M9876543210"
}
], - "demographic_info": {
- "@type": "SRPerson",
- "identifier": [
- {
- "@type": "Identifier",
- "identifier_type": "NationalID",
- "identifier_value": "9876543210"
}
], - "name": {
- "@type": "Name",
- "surname": "Smith",
- "given_name": "Alice",
- "prefix": "Ms.",
- "suffix": ""
}, - "sex": "female",
- "address": {
- "@type": "Address",
- "street_address": "123 Main St",
- "city": "Anytown",
- "postal_code": "12345",
- "country": "CountryName"
}, - "birth_date": "1985-05-20T00:00:00Z",
- "registration_date": "2022-01-10T08:00:00Z"
}, - "is_disabled": false,
- "marital_status": "married",
- "registration_date": "2022-01-10T08:00:00Z"
}, - {
- "@type": "Member",
- "member_identifier": [
- {
- "@type": "Identifier",
- "identifier_type": "NationalID",
- "identifier_value": "M9876543210"
}
], - "demographic_info": {
- "@type": "SRPerson",
- "spdci:identifier": [
- {
- "@type": "Identifier",
- "identifier_type": "NationalID",
- "identifier_value": "1234567890"
}
], - "name": {
- "@type": "Name",
- "surname": "Smith",
- "given_name": "Bob",
- "prefix": "Mr.",
- "suffix": ""
}, - "sex": "male",
- "address": {
- "@type": "Address",
- "street_address": "123 Main St",
- "city": "Anytown",
- "postal_code": "12345",
- "country": "CountryName"
}, - "birth_date": "1982-03-15T00:00:00Z",
- "registration_date": "2022-01-10T08:00:00Z"
}, - "is_disabled": false,
- "marital_status": "married",
- "registration_date": "2022-01-10T08:00:00Z"
}, - {
- "@type": "Member",
- "member_identifier": [
- {
- "@type": "Identifier",
- "identifier_type": "NationalID",
- "identifier_value": "9876543210"
}
], - "demographic_info": {
- "@type": "SRPerson",
- ":identifier": [
- {
- "@type": "Identifier",
- "identifier_type": "NationalID",
- "identifier_value": "9876543221"
}
], - "name": {
- "@type": "cName",
- "surname": "Smith",
- "given_name": "Charlie",
- "prefix": "",
- "suffix": ""
}, - "sex": "male",
- "address": {
- "@type": "Address",
- "street_address": "123 Main St",
- "city": "Anytown",
- "postal_code": "12345",
- "country": "CountryName"
}, - "birth_date": "2010-07-05T00:00:00Z",
- "registration_date": "2022-01-10T08:00:00Z"
}, - "is_disabled": false,
- "marital_status": "single",
- "registration_date": "2022-01-10T08:00:00Z"
}, - {
- "@type": "Member",
- "member_identifier": "M987654323",
- "demographic_info": {
- "@type": "SRPerson",
- "identifier": [
- {
- "@type": "Identifier",
- "identifier_type": "NationalID",
- "identifier_value": "9876543232"
}
], - "name": {
- "@type": "Name",
- "surname": "Smith",
- "given_name": "Daisy",
- "prefix": "",
- "suffix": ""
}, - "sex": "female",
- "address": {
- "@type": "Address",
- "street_address": "123 Main St",
- "city": "Anytown",
- "postal_code": "12345",
- "country": "CountryName"
}, - "birth_date": "2012-09-22T00:00:00Z",
- "sregistration_date": "2022-01-10T08:00:00Z"
}, - "is_disabled": false,
- "marital_status": "single",
- "spdci:registration_date": "2022-01-10T08:00:00Z"
}
], - "registration_date": "2022-01-10T08:00:00Z",
- "last_updated": "2023-06-15T10:00:00Z",
- "additional_attributes": [
- {
- "services": "receives_subsidy"
}
]
}
]
}, - "pagination": {
- "page_size": 2000,
- "page_number": 5,
- "total_count": 24250
}, - "locale": "en"
}
]
}
}
{- "errors": [
- {
- "code": "string",
- "message": "string"
}
]
}
The /registry/txn/status will be implemented by SR. This will check status of reach request using transaction_id and/or reference_id(s).
signature | string (MsgSignature) Signature of {header}+{message} body verified using sender's signing public key |
required | object Message header |
required | TxnStatusRequest (object) or EncryptedMessage (object) |
{- "signature": "Signature: namespace=\"spdci\", kidId=\"{sender_id}|{unique_key_id}|{algorithm}\", algorithm=\"ed25519\", created=\"1606970629\", expires=\"1607030629\", headers=\"(created) (expires) digest\", signature=\"Base64(signing content)",
- "header": {
- "version": "1.0.0",
- "message_id": "123",
- "message_ts": "",
- "action": "txn-status",
- "sender_id": "spmis.example.org",
- "receiver_id": "social.example.org",
- "total_count": 21800,
- "is_msg_encrypted": false,
- "meta": { }
}, - "message": {
- "transaction_id": 123456789,
- "txnstatus_request": {
- "reference_id": "12345678901234567890",
- "txn_type": "search",
- "attribute_type": "transaction_id",
- "attribute_value": 123456789,
- "locale": "en"
}
}
}
{- "errors": [
- {
- "code": "string",
- "message": "string"
}
]
}
The /registry/txn/on-status will be implemented by SPMIS. The response with information about request and in some case it may contain data as well.
signature | string (MsgSignature) Signature of {header}+{message} body verified using sender's signing public key |
required | object Message header |
TxnStatusResponse (object) or EncryptedMessage (object) |
{- "signature": "Signature: namespace=\"spdci\", kidId=\"{sender_id}|{unique_key_id}|{algorithm}\", algorithm=\"ed25519\", created=\"1606970629\", expires=\"1607030629\", headers=\"(created) (expires) digest\", signature=\"Base64(signing content)",
- "header": {
- "version": "1.0.0",
- "message_id": "789",
- "message_ts": "",
- "action": "txn-on-status",
- "status": "rcvd",
- "status_reason_code": "rjct.version.invalid",
- "status_reason_message": "string",
- "total_count": 21800,
- "completed_count": 50,
- "sender_id": "social.example.org",
- "receiver_id": "spmis.example.org",
- "is_msg_encrypted": false,
- "meta": { }
}, - "message": {
- "transaction_id": 123456789,
- "correlation_id": "9876543210",
- "txnstatus_response": {
- "type": "object",
- "description": "Response to search request. Multiple repsonses for each page can be pushed to the caller as an implementation!",
- "properties": {
- "transaction_id": {
- "$ref": "#/components/schemas/SearchRequest/properties/transaction_id"
}, - "correlation_id": {
- "$ref": "#/components/schemas/SearchResponse/properties/correlation_id"
}, - "search_response": {
- "type": "array",
- "items": {
- "type": "object",
- "properties": {
- "reference_id": {
- "$ref": "#/components/schemas/TxnStatusRequest/properties/txnstatus_request/properties/reference_id"
}, - "timestamp": {
- "$ref": "#/components/schemas/MsgHeader_V1.0.0/properties/message_ts"
}, - "status": {
- "$ref": "#/components/schemas/MsgCallbackHeader_V1.0.0/properties/status"
}, - "status_reason_code": {
- "$ref": "#/components/schemas/SearchStatusReasonCode"
}, - "status_reason_message": {
- "description": "Status reason code message. Helps actionable messaging for systems/end users",
- "type": "string",
- "maxLength": 999
}, - "data": {
- "type": "object",
- "description": "Search result record as an outcome of search/subscribe action\n",
- "properties": {
- "version": {
- "type": "string",
- "default": "1.0.0"
}, - "reg_records": {
- "description": "The \"Beneficiary\" object contains fields expected in response of search\n@context: https://schema.spdci.org/extensions/ibr/v1/Beneficiary.jsonld <br>\n@type: \"@context\" <br>\n@container: \"@set\" <br>\n",
- "type": "array",
- "items": {
- "type": "object",
- "description": "1. Attributes of a person to create fetch records, create verifiable credentials or use in search criteria.\n3. Allows Country/Registry specific implementation extensions using Attribute Name/Value pairs.\n\n@context: https://schema.spdci.org/extensions/ibr/v1/Beneficairy.jsonld <br>\n@type: \"@context\" <br>\n",
- "example": {
- "@context": {
}, - "@id": "Beneficiary",
- "@type": "Beneficiary",
- "assistance_unit": "1",
- "member": {
- "member_identifier": "HS0205202401",
- "demographic_info": {
- "person": {
- "identifier_type": "NID",
- "identifier_value": "0205202401",
- "name": {
- "first_name": "Test",
- "second_name": "Test2",
- "surname": "Test3"
}, - "sex": "F",
- "birth_date": "02.05.2004",
- "death_date": "",
- "address": "",
- "phone_number": "",
- "email": ""
}
}, - "relationship_head": "",
- "related_person": "",
- "is_disabled": "0",
- "disability_info": "",
- "marital_status": "Single",
- "employment_status": "employed",
- "occupation": "Caregiver",
- "income_level": "",
- "language_code": "Eng",
- "education_level": "Highschool",
- "additional_attributes": "",
- "registration_date": "02.05.2024",
- "last_update": "",
- "programme_identifier": {
- "programme": {
- "programme_identifier": "DCI001",
- "programme_name": "Test Programme"
}, - "enrolment_date": "02.02.2024",
- "enrolment_status": "Active",
- "status_change_date": "",
- "benefits": {
- "benefit_type": "Cash",
- "benefit_date": "02.05.2024",
- "benefit_value": "USD 50",
- "benefit_frequency": "Monthly"
}
}
}
}
}
}
}, - "required": [
- "reg_records"
]
}, - "pagination": {
- "$ref": "#/components/schemas/SearchResponse/properties/search_response/items/properties/pagination"
}, - "locale": {
- "$ref": "#/components/schemas/TxnStatusRequest/properties/txnstatus_request/properties/locale"
}
}, - "required": [
- "reference_id",
- "timestamp",
- "status"
]
}
}
}, - "required": [
- "transaction_id",
- "correlation_id",
- "search_response"
]
}
}
}
{- "errors": [
- {
- "code": "string",
- "message": "string"
}
]
}
The sync search api will accept request and will send response immediately The search request message consist of reg_event_type, query_type, query, sort, pagination, consent, authorize, locale. The SR will validate the request and will send response to on-search endpoint. Information for each field is given below.
signature | string (MsgSignature) Signature of {header}+{message} body verified using sender's signing public key |
required | object Message header |
required | SearchRequest (object) or EncryptedMessage (object) The search data using which registry search to be performed |
{- "signature": "Signature: namespace=\"spdci\", kidId=\"{sender_id}|{unique_key_id}|{algorithm}\", algorithm=\"ed25519\", created=\"1606970629\", expires=\"1607030629\", headers=\"(created) (expires) digest\", signature=\"Base64(signing content)",
- "header": {
- "version": "1.0.0",
- "message_id": "123",
- "message_ts": "",
- "action": "search",
- "sender_id": "spmis.example.org",
- "receiver_id": "social.example.org",
- "total_count": 21800,
- "is_msg_encrypted": false,
- "meta": { }
}, - "message": {
- "transaction_id": 123456789,
- "search_request": [
- {
- "reference_id": "12345678901234567890",
- "timestamp": "",
- "search_criteria": {
- "version": "1.0.0",
- "reg_event_type": "REGISTER",
- "query_type": "expression",
- "response_entity": "Group",
- "query": {
- "type": "ns:org:QueryType:NoSql",
- "value": {
- "expression": {
- "collection": "Group",
- "query": {
- "$and": [
- {
- "poverty_score": {
- "$lt": 5
}
}, - {
- "location": {
- "$eq": "central_region"
}
}, - {
- "group_size": {
- "$lt": 5
}
}
]
}
}
}
}, - "sort": [
- {
- "attribute_name": "poverty_score",
- "sort_order": "asc"
}
], - "pagination": {
- "page_size": 2000,
- "page_number": 5
}, - "consent": {
- "@type": "Consent",
- "ts": {
- "$ref": "#/components/schemas/MsgHeader_V1.0.0/properties/message_ts"
}, - "purpose": {
- "text": {
- "type": "string"
}, - "code": {
- "type": "string",
- "description": "From a fixed set, documented at refUri"
}, - "ref_uri": {
- "type": "string",
- "format": "uri",
- "description": "Uri to provide more info on consent codes"
}
}
}, - "authorize": {
- "@type": "Authorize",
- "ts": {
- "$ref": "#/components/schemas/MsgHeader_V1.0.0/properties/message_ts"
}, - "purpose": {
- "text": {
- "type": "string"
}, - "code": {
- "type": "string",
- "description": "From a fixed set, documented at refUri"
}, - "ref_uri": {
- "type": "string",
- "format": "uri",
- "description": "Uri to provide more info on authorize codes"
}
}
}
}, - "locale": "en"
}
]
}
}
{- "errors": [
- {
- "code": "string",
- "message": "string"
}
]
}
The /registry/sync/txn/status will be implemented by SR. This will check status of reach request using transaction_id and/or reference_id(s).
signature | string (MsgSignature) Signature of {header}+{message} body verified using sender's signing public key |
required | object Message header |
required | TxnStatusRequest (object) or EncryptedMessage (object) |
{- "signature": "Signature: namespace=\"spdci\", kidId=\"{sender_id}|{unique_key_id}|{algorithm}\", algorithm=\"ed25519\", created=\"1606970629\", expires=\"1607030629\", headers=\"(created) (expires) digest\", signature=\"Base64(signing content)",
- "header": {
- "version": "1.0.0",
- "message_id": "123",
- "message_ts": "",
- "action": "txn-status",
- "sender_id": "spmis.example.org",
- "receiver_id": "social.example.org",
- "total_count": 21800,
- "is_msg_encrypted": false,
- "meta": { }
}, - "message": {
- "transaction_id": 123456789,
- "txnstatus_request": {
- "reference_id": "12345678901234567890",
- "txn_type": "search",
- "attribute_type": "transaction_id",
- "attribute_value": 123456789,
- "locale": "en"
}
}
}
{- "errors": [
- {
- "code": "string",
- "message": "string"
}
]
}
transaction_id required | string <= 99 characters
|
required | Array of objects
|
{- "transaction_id": 123456789,
- "search_request": [
- {
- "reference_id": "12345678901234567890",
- "timestamp": "",
- "search_criteria": {
- "version": "1.0.0",
- "reg_event_type": "REGISTER",
- "query_type": "expression",
- "response_entity": "Group",
- "query": {
- "type": "ns:org:QueryType:NoSql",
- "value": {
- "expression": {
- "collection": "Group",
- "query": {
- "$and": [
- {
- "poverty_score": {
- "$lt": 5
}
}, - {
- "location": {
- "$eq": "central_region"
}
}, - {
- "group_size": {
- "$lt": 5
}
}
]
}
}
}
}, - "sort": [
- {
- "attribute_name": "poverty_score",
- "sort_order": "asc"
}
], - "pagination": {
- "page_size": 2000,
- "page_number": 5
}, - "consent": {
- "@type": "Consent",
- "ts": {
- "$ref": "#/components/schemas/MsgHeader_V1.0.0/properties/message_ts"
}, - "purpose": {
- "text": {
- "type": "string"
}, - "code": {
- "type": "string",
- "description": "From a fixed set, documented at refUri"
}, - "ref_uri": {
- "type": "string",
- "format": "uri",
- "description": "Uri to provide more info on consent codes"
}
}
}, - "authorize": {
- "@type": "Authorize",
- "ts": {
- "$ref": "#/components/schemas/MsgHeader_V1.0.0/properties/message_ts"
}, - "purpose": {
- "text": {
- "type": "string"
}, - "code": {
- "type": "string",
- "description": "From a fixed set, documented at refUri"
}, - "ref_uri": {
- "type": "string",
- "format": "uri",
- "description": "Uri to provide more info on authorize codes"
}
}
}
}, - "locale": "en"
}
]
}
transaction_id required | string <= 99 characters
|
correlation_id required | string <= 99 characters
|
required | Array of objects |
{- "transaction_id": 123456789,
- "correlation_id": "9876543210",
- "search_response": [
- {
- "reference_id": "12345678901234567890",
- "timestamp": "",
- "status": "rcvd",
- "status_reason_code": "rjct.reference_id.invalid",
- "status_reason_message": "string",
- "data": {
- "version": "1.0.0",
- "reg_records": [
- {
- "@context": {
}, - "@type": "spdci:Group",
- "group_identifier": [
- {
- "@type": "Identifier",
- "identifier_type": "NationalID",
- "identifier_value": "G9876543210"
}
], - "group_type": "family",
- "place": {
- "@type": "Place",
- "geo": {
- "@type": "GeoCoordinates",
- "latitude": "40.712776",
- "longitude": "-74.005974"
}, - "address": "123 Main St, Anytown, CountryName"
}, - "place_address": 1,
- "poverty_score": 45.2,
- "poverty_score_type": "income-based",
- "group_head_info": {
- "@type": "spdci:Member",
- "member_identifier": [
- {
- "@type": "Identifier",
- "identifier_type": "NationalID",
- "identifier_value": "M9876543210"
}
], - "demographic_info": {
- "@type": "SRPerson",
- "identifier": [
- {
- "@type": "Identifier",
- "identifier_type": "NationalID",
- "identifier_value": "9876543210"
}
], - "name": {
- "@type": "Name",
- "surname": "Smith",
- "given_name": "Alice",
- "prefix": "Ms.",
- "suffix": ""
}, - "sex": "female",
- "address": {
- "@type": "Address",
- "street_address": "123 Main St",
- "city": "Anytown",
- "postal_code": "12345",
- "country": "CountryName"
}, - "birth_date": "1985-05-20T00:00:00Z",
- "registration_date": "2022-01-10T08:00:00Z"
}, - "is_disabled": false,
- "marital_status": "married",
- "registration_date": "2022-01-10T08:00:00Z"
}, - "group_size": 4,
- "member_list": [
- {
- "@type": "Member",
- "member_identifier": [
- {
- "@type": "Identifier",
- "identifier_type": "NationalID",
- "identifier_value": "M9876543210"
}
], - "demographic_info": {
- "@type": "SRPerson",
- "identifier": [
- {
- "@type": "Identifier",
- "identifier_type": "NationalID",
- "identifier_value": "9876543210"
}
], - "name": {
- "@type": "Name",
- "surname": "Smith",
- "given_name": "Alice",
- "prefix": "Ms.",
- "suffix": ""
}, - "sex": "female",
- "address": {
- "@type": "Address",
- "street_address": "123 Main St",
- "city": "Anytown",
- "postal_code": "12345",
- "country": "CountryName"
}, - "birth_date": "1985-05-20T00:00:00Z",
- "registration_date": "2022-01-10T08:00:00Z"
}, - "is_disabled": false,
- "marital_status": "married",
- "registration_date": "2022-01-10T08:00:00Z"
}, - {
- "@type": "Member",
- "member_identifier": [
- {
- "@type": "Identifier",
- "identifier_type": "NationalID",
- "identifier_value": "M9876543210"
}
], - "demographic_info": {
- "@type": "SRPerson",
- "spdci:identifier": [
- {
- "@type": "Identifier",
- "identifier_type": "NationalID",
- "identifier_value": "1234567890"
}
], - "name": {
- "@type": "Name",
- "surname": "Smith",
- "given_name": "Bob",
- "prefix": "Mr.",
- "suffix": ""
}, - "sex": "male",
- "address": {
- "@type": "Address",
- "street_address": "123 Main St",
- "city": "Anytown",
- "postal_code": "12345",
- "country": "CountryName"
}, - "birth_date": "1982-03-15T00:00:00Z",
- "registration_date": "2022-01-10T08:00:00Z"
}, - "is_disabled": false,
- "marital_status": "married",
- "registration_date": "2022-01-10T08:00:00Z"
}, - {
- "@type": "Member",
- "member_identifier": [
- {
- "@type": "Identifier",
- "identifier_type": "NationalID",
- "identifier_value": "9876543210"
}
], - "demographic_info": {
- "@type": "SRPerson",
- ":identifier": [
- {
- "@type": "Identifier",
- "identifier_type": "NationalID",
- "identifier_value": "9876543221"
}
], - "name": {
- "@type": "cName",
- "surname": "Smith",
- "given_name": "Charlie",
- "prefix": "",
- "suffix": ""
}, - "sex": "male",
- "address": {
- "@type": "Address",
- "street_address": "123 Main St",
- "city": "Anytown",
- "postal_code": "12345",
- "country": "CountryName"
}, - "birth_date": "2010-07-05T00:00:00Z",
- "registration_date": "2022-01-10T08:00:00Z"
}, - "is_disabled": false,
- "marital_status": "single",
- "registration_date": "2022-01-10T08:00:00Z"
}, - {
- "@type": "Member",
- "member_identifier": "M987654323",
- "demographic_info": {
- "@type": "SRPerson",
- "identifier": [
- {
- "@type": "Identifier",
- "identifier_type": "NationalID",
- "identifier_value": "9876543232"
}
], - "name": {
- "@type": "Name",
- "surname": "Smith",
- "given_name": "Daisy",
- "prefix": "",
- "suffix": ""
}, - "sex": "female",
- "address": {
- "@type": "Address",
- "street_address": "123 Main St",
- "city": "Anytown",
- "postal_code": "12345",
- "country": "CountryName"
}, - "birth_date": "2012-09-22T00:00:00Z",
- "sregistration_date": "2022-01-10T08:00:00Z"
}, - "is_disabled": false,
- "marital_status": "single",
- "spdci:registration_date": "2022-01-10T08:00:00Z"
}
], - "registration_date": "2022-01-10T08:00:00Z",
- "last_updated": "2023-06-15T10:00:00Z",
- "additional_attributes": [
- {
- "services": "receives_subsidy"
}
]
}
]
}, - "pagination": {
- "page_size": 2000,
- "page_number": 5,
- "total_count": 24250
}, - "locale": "en"
}
]
}
transaction_id required | string <= 99 characters
|
required | object |
{- "transaction_id": 123456789,
- "txnstatus_request": {
- "reference_id": "12345678901234567890",
- "txn_type": "search",
- "attribute_type": "transaction_id",
- "attribute_value": 123456789,
- "locale": "en"
}
}
transaction_id required | string <= 99 characters
|
correlation_id required | string <= 99 characters
|
required | object |
{- "transaction_id": 123456789,
- "correlation_id": "9876543210",
- "txnstatus_response": {
- "type": "object",
- "description": "Response to search request. Multiple repsonses for each page can be pushed to the caller as an implementation!",
- "properties": {
- "transaction_id": {
- "$ref": "#/components/schemas/SearchRequest/properties/transaction_id"
}, - "correlation_id": {
- "$ref": "#/components/schemas/SearchResponse/properties/correlation_id"
}, - "search_response": {
- "type": "array",
- "items": {
- "type": "object",
- "properties": {
- "reference_id": {
- "$ref": "#/components/schemas/TxnStatusRequest/properties/txnstatus_request/properties/reference_id"
}, - "timestamp": {
- "$ref": "#/components/schemas/MsgHeader_V1.0.0/properties/message_ts"
}, - "status": {
- "$ref": "#/components/schemas/MsgCallbackHeader_V1.0.0/properties/status"
}, - "status_reason_code": {
- "$ref": "#/components/schemas/SearchStatusReasonCode"
}, - "status_reason_message": {
- "description": "Status reason code message. Helps actionable messaging for systems/end users",
- "type": "string",
- "maxLength": 999
}, - "data": {
- "type": "object",
- "description": "Search result record as an outcome of search/subscribe action\n",
- "properties": {
- "version": {
- "type": "string",
- "default": "1.0.0"
}, - "reg_records": {
- "description": "The \"Beneficiary\" object contains fields expected in response of search\n@context: https://schema.spdci.org/extensions/ibr/v1/Beneficiary.jsonld <br>\n@type: \"@context\" <br>\n@container: \"@set\" <br>\n",
- "type": "array",
- "items": {
- "type": "object",
- "description": "1. Attributes of a person to create fetch records, create verifiable credentials or use in search criteria.\n3. Allows Country/Registry specific implementation extensions using Attribute Name/Value pairs.\n\n@context: https://schema.spdci.org/extensions/ibr/v1/Beneficairy.jsonld <br>\n@type: \"@context\" <br>\n",
- "example": {
- "@context": {
}, - "@id": "Beneficiary",
- "@type": "Beneficiary",
- "assistance_unit": "1",
- "member": {
- "member_identifier": "HS0205202401",
- "demographic_info": {
- "person": {
- "identifier_type": "NID",
- "identifier_value": "0205202401",
- "name": {
- "first_name": "Test",
- "second_name": "Test2",
- "surname": "Test3"
}, - "sex": "F",
- "birth_date": "02.05.2004",
- "death_date": "",
- "address": "",
- "phone_number": "",
- "email": ""
}
}, - "relationship_head": "",
- "related_person": "",
- "is_disabled": "0",
- "disability_info": "",
- "marital_status": "Single",
- "employment_status": "employed",
- "occupation": "Caregiver",
- "income_level": "",
- "language_code": "Eng",
- "education_level": "Highschool",
- "additional_attributes": "",
- "registration_date": "02.05.2024",
- "last_update": "",
- "programme_identifier": {
- "programme": {
- "programme_identifier": "DCI001",
- "programme_name": "Test Programme"
}, - "enrolment_date": "02.02.2024",
- "enrolment_status": "Active",
- "status_change_date": "",
- "benefits": {
- "benefit_type": "Cash",
- "benefit_date": "02.05.2024",
- "benefit_value": "USD 50",
- "benefit_frequency": "Monthly"
}
}
}
}
}
}
}, - "required": [
- "reg_records"
]
}, - "pagination": {
- "$ref": "#/components/schemas/SearchResponse/properties/search_response/items/properties/pagination"
}, - "locale": {
- "$ref": "#/components/schemas/TxnStatusRequest/properties/txnstatus_request/properties/locale"
}
}, - "required": [
- "reference_id",
- "timestamp",
- "status"
]
}
}
}, - "required": [
- "transaction_id",
- "correlation_id",
- "search_response"
]
}
}
required | object |
ciphertext required | string This is the result of encrypting the plaintext using the CEK and the IV. It's Base64Url-encoded. |
encrypted_key required | string The base64-url encoded encrypted key |
tag required | string This is a Base64Url-encoded value that provides evidence of the integrity and authenticity of the ciphertext, Initialization Vector, and Additional Authenticated Data |
iv required | string This is a Base64Url-encoded random bit string to be used as the Initialization Vector (IV) when encrypting the plaintext to produce the ciphertext. The size of the IV depends on the encryption algorithm used. |
{- "header": {
- "alg": "string",
- "enc": "string",
- "kid": "string"
}, - "ciphertext": "string",
- "encrypted_key": "string",
- "tag": "string",
- "iv": "string"
}
Identity verification request status reason codes
"rjct.reference_id.invalid"