Unload API Method

This operation performs a debit on the account for the requested unload amount, provided that all the validations are successful.

📘

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

Syntax

POST {baseUrl}/unload/execute

Example Request

Success Request

POST {baseUrl}/unload/execute
Authorization: bearer {token}
Content-Type: application/json
X-GD-RequestId: test101
{
    "metadata": {
        "merchantId": "fscc0342",
        "registerId": "01",
        "requestDateTime": "2023-10-11T07:53:32Z",
        "storeId": "CC970",
        "userId": "[email protected]"
    },
    "accountNumber": "",
    "amount": 10.00,    
    "accountIdentifier": "007f8f2d-f1be-49c1-b029-ef6dcc902006" 
}

Negative Request

POST {baseUrl}/unload/execute
Authorization: bearer {token}
Content-Type: application/json
X-GD-RequestId: test101
{
    "metadata": {
        "merchantId": "fscc0342",
        "registerId": "01",
        "requestDateTime": "2023-10-11T07:48:39Z",
        "storeId": "CC970",
        "userId": "[email protected]"
    },
    "accountNumber": "",
    "amount": 100.00,    
    "accountIdentifier": "d85972b5-6912-4301-ab6f-94aa49ef7076" 
}

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 user generating the transaction.
storeIdYesStringMaxLength: 20The store number associated with the retailer that sold the package.
If not supplied, InvalidParameter (Code:100) error will be return.
merchantIdYesStringMaxLength: 20The unique merchant Id. Defined by Green Dot – Merchant corresponding with Retailer.
accountNumberNoString16 digits PANAccount Number (PAN) of the card.
Note: Either AccountNumber or AccountIdentifier is required
amountYesDecimal500.00Amount of money to be unload.
For example: Five Hundred Dollars is entered as 500.00. Twenty Dollars is entered as 20.00)
accountIdentifierNoGUIDe5843e05-d367-4bf1-a223-3af46ae18802Newly created unique identifier for sale card, should be using for all subsequent API calls
Note: Either AccountNumber or AccountIdentifier is required

Example Response

Success Response:

HTTP/1.1 200 OK
Content-Type: application/json
X-GD-RequestId: test101
X-GD-ResponseId: c07cdd09-85a8-438b-97bc-9c50745d3631
X-GD-ResponseCode: 0

{
    "balance": "370.00",
    "transactionIdentifier": "c07cdd09-85a8-438b-97bc-9c50745d3631",
    "metadata": {
        "requestId": "test101",
        "responseId": "c07cdd09-85a8-438b-97bc-9c50745d3631",
        "responseDateTime": "2023-10-11T07:53:36.1198386Z",
        "responseCode": 0,
        "responseDescription": "Success"
    }
}

Negative Response

HTTP/1.1 200 OK
Content-Type: application/json
X-GD-RequestId: test101
X-GD-ResponseId: 326f0ed2-dc63-4412-aaf6-ee021505ab39
X-GD-ResponseCode: 110

{
    "balance": null,
"transactionIdentifier": null,
    "metadata": {
     "requestId": "test101",
     "responseId": "326f0ed2-dc63-4412-aaf6-ee021505ab39",
     "responseDateTime": "2023-10-11T07:48:43.2219632Z",
     "responseCode": 110,
     "responseDescription": "Account Status is Locked"
    }
}

Response Parameters

ParameterRequired(Y/N)Format/Data TypePatternDescription
requestIdYesStringMaxLength:50The unique request ID from 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.
balanceYesString50.00Balance after unload. If transaction validation fails, this field is null.
transactionIdentifierNoGUIDe5843e05-d367-4bf1-a223-3af46ae18802Newly created unique identifier for transaction. If transaction validation fails, this field is null.

Response Cases

CodeCodeTextResponseDescriptionDescription
0SuccessSuccess.
100InvalidParameter• RequestId is required
• UserId is required
• RequestDateTime is required
• StoreId is required
• MerchantId is required
• RequestId is too long
• UserId is too long
• StoreId is too long
• MerchantId is too long
• Invalid length of AccountNumber
• Either AccountNumber or AccountIdentifier is required
Invalid parameter in the request. Examples: MerchantID not supplied, StoreID not supplied.
130InvalidMerchantInvalidMerchantMerchantId in request has not been found/enabled in the system.
800InvalidStore• Store feature is invalid
• Store was not found
• Block by Store Hierarchy setting
Store is not found; store is not for the partner or store does not support this operation.
861RetailChainUserNotFoundUser is not found.UserID in request is not found in system.
862RetailChainUserNotActiveUser is not active.UserId in request is not active.
700LoadLimitValidationFailed• Exceeds account daily unload limit
• Exceeds account monthly unload limit
• Unload amount of Non-active initial card should equal to available balance.
• The account has insufficient funds to execute the transfer.
• amount must be greater than zero.
Per transaction, account balance, daily account reload limit reached or insufficient fund on account.
110InvalidAccountNumber• ProgramCode does not match the card
• AccountStatus is Closed.
• AccountStatus is Pending.
• AccountStatus is Locked.
• Account Status is Restricted
• Account Not Found.
• AccountNotFound
Account is not found; account status is not valid, or account is not unloadable
600UnableToProcessRequestUnable to process request due to downstream errors.
1000GeneralFailureGeneralFailureService failure.