cisco-cvp-ux
Get PaymentMethod - TMF670 GET
GET
This operation gets payment information.
URL
http://[host]:[port]/cisco-cvp-ux/v1/{businessId}/paymentMethod
Common Parameters
Base URI parameters and headers are common to all the resources as part of payment-methods Biz API, listed below with details.
Base URI Parameter
Name | Type | M/O | Description |
---|---|---|---|
businessId | string | M | Business unit identifier. Example: PR |
Query Parameter
Name | Type | M/O | Description |
---|---|---|---|
accountId | string | O | Aria AccountId of the customer |
accountId.relatedParty.id | string | O | Phone Number of the customer |
Note : Either of above query parameters should be sent
Headers
Name | Type | M/O | Description |
---|---|---|---|
X-Correlation-ID | string | M | This is a unique identifier for the current call chain that can be used to tie together log entries on multiple layers. Example: 644e1dd7-2a7f-18fb-b8ed-ed78c3F92c2b |
lob | string | M | The Line of Business Identifier currently available are: FIXED, POSTPAID or PREPAID |
channelId | string | O | Channel to identify the business group. Ex: ivrB2C |
Security Headers
Name | Type | M/O | Description |
---|---|---|---|
client_id | string | M | Client Id value for Client Id Enforcement policy. Environment Specific Value. Eg: 6f0ed16a7b494d76b2d60e05bc3b3332 |
client_secret | string | M | Client secret value for Client Id Enforcement policy. Environment Specific Value, eg: e4CD4D43449846aA9D8Cb9c43fAd324a |
Response
Possible response success
This section defines all the possible data structures received by the client and that must be considered satisfactory at the time of responding to the method.
Success Response
[
{
"id": "2",
"token": "cGF5bWVudG1ldGhvZF9jY19tMHpxNTl6cQ",
"@type": "Tokenised Credit Card",
"@baseType": "paymentMethod",
"account": [
{
"id": "31516278-31514752",
"@type": "BillingAccount",
"ratingType": "Prepaid",
"autopayEnabled": "true"
}
],
"relatedParty": [
{
"name": "BrainTreeToken",
"@type": "paymentGatewayType"
}
],
"autopayEnabled": "true"
}
]
Definitions
name | type | description | required |
---|---|---|---|
id | string | Unique Identifier within the server for the payment method. | N |
token | string | token details of a tokenized bank card | N |
@type | string | Type of payment method | N |
@baseType | string | it is the payment method | N |
account | array | Reference to the accounts that are linked to the payment method.. A account may be a party account or a financial account. | N |
account.id | string | Unique identifier of the account | N |
account.'@type' | string | type of the account | N |
account.name | string | Name of the account | N |
account.ratingType | string | Name of the ratingType | N |
account.autopayEnabled | string | field which tells whether account has autopay is enabled or not | N |
relatedParty | array | Information about an associated entity and its role. Account that owns the payment method | N |
relatedParty.name | string | name of the related party | N |
relatedParty.@type | string | Type of party | N |
autopayEnabled | string | field which tells whether payment method has autopay is enabled or not | N |
Possible error response
[ 400 ]
Bad Request - the request could not be understood by the server due to malformed syntax. The client SHOULD NOT repeat the request without modifications.
{
"errors" : [{
"code" : 400,
"message" : "The request is invalid or not properly formed.",
"description" : "The client sent too many requests and server is not able to serve them all at the moment"
}]
}
[ 401 ]
Unauthorized - The request has not been applied because it lacks valid authentication credentials for the target resource.
{
"errors" : [{
"code" : 401,
"message" : "The user could not be authenticated for this request.",
"description" : "The request has not been applied because it lacks valid authentication credentials for the target resource"
}]
}
[ 403 ]
Forbidden - Indicates that the server understood the request but refuses to fulfill it. If authentication credentials were provided in the request, the server considers them insufficient to grant access. The client SHOULD NOT automatically repeat the request with the same credentials. The client MAY repeat the request with new or different credentials.
[ 404 ]
Not Found - server has not found a resource with that URI. This may be temporary and permanent condition. This status code is commonly used when the server does not wish to reveal exactly why the request has been refused, or when no other response is applicable.
{
"errors" : [{
"code" : 404,
"message" : "The request is invalid or not properly formed.",
"description" : "The requested operation failed because a resource associated with the request could not be found."
}]
}
[ 405 ]
Method Not Allowed - HTTP method not allowed for this resource. The method specified in the Request-Line is not allowed for the resource identified by the Request-URI.
{
"errors": [{
"code": 405,
"message": "APIKIT:METHOD_NOT_ALLOWED",
"description": "HTTP Method PATCH not allowed for : /{businessId}/paymentMethod"
}]
}
[ 500 ]
Internal Server Error - server encountered an error processing request. This should not happen normally, but it is a generic error message, given when no more specific message is suitable.
{
"errors" : [{
"code" : 500,
"message" : "The request failed due to an internal error.",
"description": "error description"
}
]
}
[ 501 ]
Check for the other BU Flows, if not implemented then throw a standard error message as below.
{
"errors": [
{
"code": 501,
"message": "NOT_IMPLEMENTED",
"description": "Operation GET /paymentMethod for Business Id: SX not implemented"
}
]
}
[ 503 ]
Service Unavailable
{
"errors": [
{
"code": 503,
"message": "HTTP:SERVICE_UNAVAILABLE",
"description": "HTTP GET on resource 'http://0.0.0.0:9092/cisco-cvp-ux/v1/PR/paymentMethod' failed: service unavailable (503)."
}
]
}