Search API Method

This operation is used to search by various parameters to retrieve the Account/Card Status Info. Only one of three options below should be used to perform search. Combination search is not supported.
• AccountNumber
• PhoneNumber
• Combination of IdentityType, IdentityNumber and IssuerCountryCode

📘

Every request triggered should have a unique X-GD-RequestId value in the header.

Syntax

POST {baseUrl}/search

Example Request

Success Request

POST {baseUrl}/search
Authorization: bearer {token}
Content-Type: application/json
X-GD-RequestId: test101

{
"phoneNumber": "",
  	"accountNumber": "",
  	"identityType": "ITIN",
  	"identityNumber": "930471923",  
  	"issuerCountryCode": "",
  	"metadata": {
    		"storeId": "CC970",
    		"merchantId": "FSCC0342",
    		"userId": "[email protected]",
    		"requestDateTime": "2023-09-28T09:32:32Z",
    		"registerId": ""
  }
}

Negative Request

POST {baseUrl}/search
Authorization: bearer {token}
Content-Type: application/json
X-GD-RequestId: test101

{
  "phoneNumber": "123",
  "accountNumber": "",
  "identityNumber": "",
  "identityType": "",
  "issuerCountryCode": "",
  "metadata": {
    "storeId": "CC970",
    "merchantId": "FSCC0342",
    "userId": "[email protected]",
    "requestDateTime": "2023-09-28T09:06:53Z",
    "registerId": "01"
  }
}

Request Parameters

ParameterRequired (Y/N)Format/ Data TypePatternDescription
X-GD-RequestIdYesStringMaxLength:50It is a unique transaction identifier that is generated by the retailer.
requestDateTimeYesDateTime2023-08-08T12:34:56ZTime stamp at which transaction occurred.
The time stamp has to be in UTC time zone and follow the following date and time formats:
• YYYY-MM-DDTHH:mm:ssZ
registerIdNoStringMaxLength: 20Register where the transaction occurred.
userIdYesStringMaxLength:50The unique ID of the user generating the transaction.
If not supplied, InvalidParameter (Code:100) error will be return.
storeIdYesStringMaxLength: 20The store number associated with the retailer that sold the package.
If not supplied, InvalidParameter (Code:100) error will be return.
merchantIdYesStringMaxLength: 20Unique merchant Id. It is defined by Green Dot – Merchant corresponding with Retailer.
If not supplied, InvalidParameter (Code:100) error will be return.
phoneNumberNoString10 digitsPhoneNumber that is used to search account. PhoneNumber has to be 10 digits
identityTypeNoStringMin: 3 , Max: 21Values can be SSN, Passport, ITIN and NationalIdCard.
Note that Mexican Matricula use nationalIdCard as Type.
identityNumberNoStringMin: 1 , Max: 50Identity Document Number value for the Identity Type.
Only numbers and alphabets are allowed in IdentityNumber field.
issuerCountryCodeNoStringMin: 3Country that issued the identification card in ISO 3166-1 alpha-3 format.
Note: For any given identity type, issuecountrycode field is mandatory.
Possible values are USA, COL, CUB, DOM, ECU, SLV, GTM, HND, MEX, NIC and VEN.
accountNumberNoString16 digits PANAccount Number (PAN) of the card.

Example Response

Success Response

HTTP/1.1 200 OK
Content-Type: application/json
X-GD-RequestId: test101
X-GD-ResponseId: 9c829539-7dfb-41d8-b536-1f25a63d240d
X-GD-ResponseCode: 0
{
	"info": [
		{
			"cardStatus": "activated",
			"accountStatus": "normal",
			"lastFourAccountNumber": "9091",
			"accountIdentifier": "06e33e98-5c40-4c1a-967b-930f28f509a4",
			"phoneNumber": "2436755891",
			"name": "Approved ITbOJjNV",
			"lastFourIdentityNumber": "1923"
		}
	],
	"metadata": {
		"requestId": "test101",
		"responseId": "9c829539-7dfb-41d8-b536-1f25a63d240d",
		"responseDateTime": "2023-09-28T09:08:27.7781206Z",
		"responseCode": 0,
		"responseDescription": "Success"
	}
}

Negative Response

HTTP/1.1 400 OK
Content-Type: application/json
X-GD-RequestId: test101
X-GD-ResponseId: 566561b7-1082-4b90-9ab3-fd2bc3878095
X-GD-ResponseCode: 100
{
  "info": null,
  "metadata": {
    "requestId": "test101",
    "responseId": "566561b7-1082-4b90-9ab3-fd2bc3878095",
    "responseDateTime": "2023-09-28T09:10:29.9634977Z",
    "responseCode": 100,
    "responseDescription": "PhoneNumber has to be 10 digits"
  }
}

Response Parameters

ParameterRequired (Y/N)Format/Data TypePatternDescription
requestIdYesStringMaxLength:50The unique request ID generated from the request.
responseIdYesStringMaxLength:50The unique Response Identifier (generated by GreenDot
responseDateTimeYesDateTime2023-09-07T16:12:23.4541445+08:00Time stamp at which transaction occurred.
The time stamp is in UTC time zone and follow the following date and time formats:
• YYYY-MM-DDTHH:mm:ssfffffffK
responseCodeYesNumericMaxLength:4Indicates success and failure of the response codes. It is in the numeric format.
responseDescriptionYesStringMaxLength:255Describes the Response Code in more detail. It is in the String format.
infoYesStringList of Account/Card Info Status. This field will be null if no record is found or validation failed.
cardStatusStringactivated
notActivated
blocked
Closed
Fixed value indicating card activation status.
accountStatusStringpending
normal
restricted
closed
locked
Fixed value indicating Account Status.
lastFourAccountNumberString4 digitsLast Four Account Number (PAN).
accountIdentifierStringe5843e05-d367-4bf1-a223-3af46ae18802Can be used for other API calls.
phoneNumberString7648329876Phone number registered for the account.
nameStringJack BauerCardholder Name of the account.
lastFourIdentityNumberString9687Last 4 Digits SSN or other Identity type value.

Response Cases

CodeCodeTextResponse DescriptionDescription
0SuccessSuccessSuccess
100InvalidParameter• Invalid parameters
• PhoneNumber has to be 10 digits
• Only numbers and alphabets are allowed in IdentityNumber field
• MerchantId is required
• StoreId is required
• UserId is required
• RequestId is required
• RequestDateTime is required
• RequestId is too long
• UserId is too long
• StoreId is too long
• MerchantId is too long
• AccountNumber has to be 16 digits
• Invalid ssn format
• IssuerCountryCode has to be 3 alphabets
Invalid parameter in the request. Examples: MerchantID not supplied, StoreID not supplied.
130InvalidMerchantInvalidMerchantMerchantId in request has not been found/enabled in the system.
800InvalidStoreStore was not foundStore is not found, store is not for the partner or store does not support this operation.
815AccountNotFoundAccountNotFoundAccount not found
861RetailChainUserNotFoundUser is not found.UserID in request is not found in system.
862RetailChainUserNotActiveUser is not active.UserId in request is not active.
1000GeneralFailureGeneralFailureService failure.