Method: getBalanceAndLimits

  • Retrieves the current account balance and transaction limits for a user associated with a provided association ID.

  • The request body requires a requestHeader and associationId, while the response includes current balance, transaction limits, and remaining daily/monthly limits.

  • In case of errors, the response will be of type ErrorResponse with corresponding HTTP status codes.

  • Possible response messages include a successful GetBalanceAndLimitsResponse (HTTP 200) or an ErrorResponse for errors (HTTP 4XX/5XX).

  • If successful, the response provides detailed information about the user's balance and limits within the GetBalanceAndLimitsSuccess object.

Initiates a request for the current account balance associated with the association ID provided in the request. The return value contains the current balance and transaction limit data for the account.

If the endpoint encounters an error while processing the request, the response body from this endpoint should be of type ErrorResponse.

An example request looks like:


{
  "requestHeader": {
    "protocolVersion": {
      "major": 1,
      "minor": 1,
      "revision": 0
    },
    "requestId": "G112YZH4XPDV88J",
    "requestTimestamp": "1481907920000"
  },
  "associationId": "LmddbXBsZSByZWZlcmVuY2UgdG9rZW4gdmFsdWU_"
}

An example response looks like:


{
  "responseHeader": {
    "responseTimestamp": "1481900013178"
  },
  "result": {
    "success": {
      "currentBalance": {
        "amountMicros": "51000000",
        "currencyCode": "USD"
      },
      "transactionMaxLimit": {
        "amountMicros": "100000000",
        "currencyCode": "USD"
      },
      "transactionMinLimit": {
        "amountMicros": "500000",
        "currencyCode": "USD"
      },
      "remainingDailyLimit": {
        "amountMicros": "200000000",
        "currencyCode": "USD"
      },
      "remainingMonthlyLimit": {
        "amountMicros": "3000000000",
        "currencyCode": "USD"
      }
    }
  }
}

HTTP request

POST https://payment-integrator-e-wallets-api.google.com/integrator-base-path/korea-e-wallets-v1/getBalanceAndLimits

Request body

The request body contains data with the following structure:

JSON representation
{
  "requestHeader": {
    object (RequestHeader)
  },
  "associationId": string
}
Fields
requestHeader

object (RequestHeader)

REQUIRED: Common header for all requests.

associationId

string

REQUIRED: The associationId of the user's account, originally provided in the associateAccount() call during account linking.

Response body

This method supports multiple return types. For additional information about what 4XX or 5XX HTTP status code to return with an ErrorResponse, consult the ErrorResponse object and HTTP status codes documentation.

Possible response messages
HTTP 200 Status

object (GetBalanceAndLimitsResponse)

HTTP 4XX / 5XX Status

object (ErrorResponse)

GetBalanceAndLimitsResponse

Response object for the get balance and limits method.

JSON representation
{
  "responseHeader": {
    object (ResponseHeader)
  },
  "result": {
    object (GetBalanceAndLimitsResult)
  }
}
Fields
responseHeader

object (ResponseHeader)

REQUIRED: Common header for all responses.

result

object (GetBalanceAndLimitsResult)

REQUIRED: The result of the korea-e-wallets-v1.getBalanceAndLimits call.

GetBalanceAndLimitsResult

Result codes for korea-e-wallets-v1.getBalanceAndLimits.

JSON representation
{

  // Union field result can be only one of the following:
  "success": {
    object (GetBalanceAndLimitsSuccess)
  },
  "accountClosed": {
    object (Empty)
  },
  "accountClosedAccountTakenOver": {
    object (Empty)
  },
  "accountClosedFraud": {
    object (Empty)
  }
  // End of list of possible types for union field result.
}
Fields
Union field result. REQUIRED: The result of the GetBalanceAndLimits call. result can be only one of the following:
success

object (GetBalanceAndLimitsSuccess)

Details if the request completed successfully.

accountClosed

object (Empty)

User's account held with the integrator has been closed.

accountClosedAccountTakenOver

object (Empty)

User's account with the integrator has been closed, suspected account take over.

accountClosedFraud

object (Empty)

User's account held with the integrator has been closed because of fraud.

GetBalanceAndLimitsSuccess

Details of a successful api call.

JSON representation
{
  "currentBalance": {
    object (Amount)
  },
  "transactionMaxLimit": {
    object (Amount)
  },
  "transactionMinLimit": {
    object (Amount)
  },
  "remainingDailyLimit": {
    object (Amount)
  },
  "remainingMonthlyLimit": {
    object (Amount)
  }
}
Fields
currentBalance

object (Amount)

REQUIRED: The user's current balance, in micros.

transactionMaxLimit

object (Amount)

OPTIONAL: The user's limit per transaction, in micros.

transactionMinLimit

object (Amount)

OPTIONAL: The minimum allowable transaction amount, in micros.

remainingDailyLimit

object (Amount)

OPTIONAL: The amount available to the user before reaching daily transaction limits, in micros.

remainingMonthlyLimit

object (Amount)

OPTIONAL: The amount available to the user before reaching monthly transaction limits, in micros.