--- swagger: "2.0" info: x-ibm-name: account-balances-api title: Account Balances API version: 1.0.0 contact: name: API developer email: apideveloper@rakbank.ae description: "This API is to get account balances of a customer account\n\n<br>\n<p><strong>OAuth2 related details</strong></p>\n<p><em>Token URL for Third Party Apps: https://sandboxapi.rakbank.ae/rb/api/v1/customer_signin/oauth2/token</em>\n\t<br>scope : account_balances\n\t<br>grant_type : authorization_code | refresh_token\n</p>\n<br>" name: "" schemes: - https host: sandboxapi.rakbank.ae basePath: /v1 consumes: - application/json produces: - application/json securityDefinitions: oauth: type: oauth2 description: "" flow: accessCode scopes: account_balances: "" tokenUrl: https://sandboxapi.rakbank.ae/rb/api/v1/customer_signin/oauth2/token authorizationUrl: https://sandboxapi.rakbank.ae/rb/api/v1/customer_signin/oauth2/authorize clientIdHeader: type: apiKey in: header name: X-IBM-Client-Id security: - clientIdHeader: [] oauth: - account_balances x-ibm-configuration: testable: true enforced: true phase: realized paths: /accounts/{account_id}/balances: get: responses: 200: description: 200 OK schema: $ref: '#/definitions/coll_balances' 401: description: Unauthorized Error schema: $ref: '#/definitions/error_response' 403: description: Forbidden Error schema: $ref: '#/definitions/error_response' 422: description: Error in case of Invalid request schema: $ref: '#/definitions/error_response' 500: description: Internal Sever Error schema: $ref: '#/definitions/error_response' operationId: GetAccountBalances description: Get account balances. parameters: - name: account_id type: string maxLength: 13 required: true in: path description: 'Account id of which balances are required. Only MASKED value to be passed. Masking logic to be followed : - First 4 and last 3 characters to be unmasked. All chracters in between to be masked by replacing with ''x''. e.g. 1234xxxxxx567' - name: MsgId type: string maxLength: 50 required: true in: header description: Unique Id sent by client. Value should be a unique identifier of the transaction in UUID format. definitions: balances: properties: type: type: string enum: - LedgerBalance - UnclearedBalance - ClearedBalance - LienAmount+SystemReservedAmount - DrawingPower - AvailableBalance - EffectiveAvailableBalance - PoolBalance - LienAmount - LedgerBalanceHomeCurrency description: Holds balance type example: EffectiveAvailableBalance balance: description: Holds account balance corresponding to 'type' $ref: '#/definitions/value' additionalProperties: false required: - type - balance description: Balance details value: properties: amount: type: string description: Holds value of the amount (Number format - 20,4) example: "2000.00" currency: type: string description: currency example: AED additionalProperties: false description: Amount details required: - amount - currency error_response: properties: status: type: string description: HTTP Status response_code: type: string description: API specific error code property: type: string response_message: type: string description: brief type of the error description: type: string description: detailed description of the error additionalProperties: false description: Response in case of error required: - status - response_code - response_message coll_balances: properties: total_count: type: integer description: Holds the total no. of balances returned example: 10 href: type: string description: href value to fetch this resource example: https://sandboxapi.rakbank.ae/rb/api/v1/accounts/1234xxxxxx123/balances balances: type: array items: $ref: '#/definitions/balances' description: array of balances additionalProperties: false description: Returns the collection of balances along with some meta data required: - href - balances tags: [] x-ibm-endpoints: - endpointUrl: https://sandboxapi.rakbank.ae/sb/api type: - production - development ...