---
swagger: "2.0"
info:
title: CRD-CCC-D-CreditCardDetails
description: This purpose of this microservice is to retrieve or manage the credit
card information related to the customer.
version: 1.4.0
x-ibm-name: crd-ccc-d-creditcarddetails
host: 127.0.0.1
schemes:
- https
basePath: /api
produces:
- application/json
paths:
/v1/cards/credit-cards/balance/retrieve:
post:
tags:
- credit-card-balance
operationId: credit-card-balance
summary: To retrieve all credit cards balance related to customer, web service
client could choose between active or inactive cards, primary and supplementary
cards, as part of the response indicates if the customer could have a premia
rewards card.
description: This API is to retrieve all credit cards balance related to customer,
web service client could choose between active or inactive cards, primary
and supplementary cards, as part of the response indicates if the customer
could have a premia rewards card.
consumes:
- application/json
produces:
- application/json
parameters:
- name: client_id
in: header
required: false
type: string
description: Client ID generated during application registration
- name: Authorization
in: header
required: false
type: string
description: The Authorization Token received during login
- name: Accept
in: header
required: true
type: string
description: Content-Types that are acceptable for the response
- name: uuid
in: header
required: true
type: string
description: 128 bit UUID that you generate for every request
- name: Accept-Language
in: header
required: false
type: string
description: List of acceptable human languages for response
- name: Content-Type
in: header
required: true
type: string
description: Content-Types that are sent in the request
- name: ChannelId
in: header
required: true
type: string
description: Channel where request originated
- name: sid
in: header
required: false
type: string
description: SessionId sent by Consumer
- name: creditCardDetailsRequest
in: body
schema:
$ref: '#/definitions/CreditCardDetailsRequest'
responses:
200:
description: Successful operation.
schema:
$ref: '#/definitions/CreditCardDetailsResponse'
400:
description:
Type | Code | Details |
error | invalidRequest | Missing
or invalid Parameters |
schema:
$ref: '#/definitions/ErrorResponse'
401:
description: Type | Code | Details |
error | unAuthorized | Authorization
credentials are missing or invalid |
schema:
$ref: '#/definitions/ErrorResponse'
403:
description: Type | Code | Details | More
Info |
error | accessNotConfigured | The request
operation is not configured to access this resource | Channel/Country/Business
provided in the request is not supported currently |
schema:
$ref: '#/definitions/ErrorResponse'
404:
description: Type | Code | Details | More
Info |
error | resourceNotFound | The requested
resource was not found | Empty resource/resource not found |
schema:
$ref: '#/definitions/ErrorResponse'
422:
description: Type | Code | Details |
error | businessValidationFailed | Business
validation error occured on one or more parameters |
schema:
$ref: '#/definitions/ErrorResponse'
500:
description: Type | Code | Details |
fatal | serverUnavailable | The
request failed due to an internal error/server unavailability |
schema:
$ref: '#/definitions/ErrorResponse'
definitions:
CreditCardDetailsRequest:
type: object
properties:
customerId:
description: Unique identifier of the customer
type: string
example: "5491380012127370"
maxLength: 16
minLength: 5
cardType:
description: Filter to define what card type (PRIMARY, SUPPLEMENTARY,BOTH) is
expected.
type: string
example: PRIMARY
enum:
- PRIMARY
- ' SUPPLEMENTARY'
- BOTH
cardStatus:
description: Filter to define what card status (ACTIVE,INACTIVE,BOTH) is expected.
type: string
example: ACTIVE
enum:
- ACTIVE
- ' INACTIVE'
- BOTH
creditCardDetail:
type: array
items:
$ref: '#/definitions/CreditCardDetail'
required:
- customerId
- cardType
- cardStatus
CreditCardDetail:
type: object
properties:
cardNumber:
description: 16 digit Card number of the credit card
type: string
example: "1234567890123456"
maxLength: 16
pattern: ^[0-9]{16}$
CreditCardDetailsResponse:
type: object
properties:
premiaRewardsFlag:
description: This is a flag that indicates if customer have premia rewards
card
type: boolean
example: true
creditCardAccount:
type: array
items:
$ref: '#/definitions/CreditCardAccount'
required:
- premiaRewardsFlag
CreditCardAccount:
type: object
properties:
cardNumber:
description: 16 digit Card number of the credit card
type: string
example: "1234567890123456"
maxLength: 16
pattern: ^[0-9]{16}$
accountNumber:
description: account number of the customer
type: string
example: "1234567890123456"
cardType:
description: Card type Primary/Supplementary
type: string
example: PRIMARY
enum:
- PRIMARY
- ' SUPPLEMENTARY'
cardStatus:
description: card status
type: string
example: NORMAL
logoId:
description: This is the logo id of the product
type: string
example: "120"
logoName:
description: This is the logo name of the product
type: string
example: Delta Airlines
currencyCode:
description: currency code of the account
type: string
example: MXN
currentBalanceAmount:
description: current balance amount-balance of the card as of today
type: number
format: double
example: 2500.990000
minimum: -9999999999999.990234
maximum: 9999999999999.990234
availableCreditAmount:
description: creditAvailableAmount of the credit card
type: number
format: double
example: 2000.990000
minimum: -9999999999999.990234
maximum: 9999999999999.990234
creditLimitAmount:
description: credit limit amount of the credit card
type: number
format: double
example: 4500.990000
minimum: -9999999999999.990234
maximum: 9999999999999.990234
cashLimitAmount:
description: cash credit limit of the credit card
type: number
format: double
example: 4000.990000
minimum: -9999999999999.990234
maximum: 9999999999999.990234
availableCashAmount:
description: cash available amount of the account
type: number
format: double
example: 4000.990000
minimum: -9999999999999.990234
maximum: 9999999999999.990234
minimumPaymentDueAmount:
description: minimum payment due amount
type: number
format: double
minimum: -9999999999999.990234
example: 1500.990000
maximum: 9999999999999.990234
lastStatementTotalBalanceAmount:
description: Statement balance amount-balance as of last statement date
type: number
format: double
example: 3000.990000
minimum: -9999999999999.990234
maximum: 9999999999999.990234
totalPaymentAmount:
description: minimumPaymentToAvoidInterest-to pay the complete pending amount
to avoid interest
type: number
format: double
example: 5000.990000
minimum: -9999999999999.990234
maximum: 9999999999999.990234
paymentDueDate:
description: payment due date
type: string
format: date
example: "2018-04-04"
lastPaymentDate:
description: Date on which the customer made the recent payment
type: string
format: date
example: "2018-05-03"
lastStatementDate:
description: Date on which the last statement was generated
type: string
format: date
example: "2018-05-05"
cardValidFlag:
description: Indicates if a card for which the details are requested is valid
or not
type: boolean
example: true
cardInvalidDescription:
description: Include a description when when the card is invalid or the above
field cardValidFlag is false
type: string
example: Card not available
required:
- cardNumber
- currencyCode
- availableCreditAmount
- creditLimitAmount
- cardValidFlag
ErrorResponse:
properties:
type:
type: string
description: Invalid - Request did not confirm to the specification and was
unprocessed and rejected. Please fix the value and try again
enum:
- error
- warn
- invalid
- fatal
code:
description: Error code which qualifies the error
type: string
details:
description: Human readable explanation specific to the occurrence of the
problem
type: string
location:
description: The name of the field that resulted in the error
type: string
moreInfo:
description: More Info can be used to pass any additional details
type: string
uuid:
description: 128 bit UUID that you generate for every request
type: string
timestamp:
description: Timestamp of the error
type: string
required:
- type
- code
x-ibm-configuration:
enforced: true
testable: true
phase: realized
consumes:
- application/json
securityDefinitions:
OAuth2 Application Flow:
type: oauth2
description: ""
flow: application
scopes:
/api/v1: ""
tokenUrl: https://perf.api.externalapib2b.wlb.lac.nsroot.net:7100/mx-gcgapi/perfext/api/v1/oauth/token
Client ID:
type: apiKey
description: ""
in: header
name: X-IBM-Client-Id
security:
- OAuth2 Application Flow:
- /api/v1
Client ID: []
x-ibm-endpoints:
- endpointUrl: https://perf.api.externalapib2b.wlb.lac.nsroot.net:7100/mx-gcgapi/perfext
type:
- production
- development
...