dxp-ux
Product-Inventory
listProduct [GET]
- The listProduct API is used to retrieve a list of purchased products and Subscriber status for LCPR.
- This operation allows to fetch the entitlement report from bango for PA.
URL
https://[localhost]:[port]/dxp-ux/v1/{businessId}/product
URL Parameter
Name | Type | Description | required |
---|---|---|---|
businessId | string | 2 letter ISO 3166 country code (TT, BB, JM, PA, PR etc.) identifying the business unit | Y(PR, PA) |
Headers
Name | Type | Description | required (mandatory-Y, optional-N, Not applicable- N/A) |
---|---|---|---|
X-Correlation-ID | string | An identifier for the current call chain that can be used to tie together log entries on multiple layers (e.g. client, server, mainframe). This identifier must be designed to be unique across all applications. Note - Mule default behavior creates a sample x-correlation-id field if value is not passed from client, API will use this value in case value is not passed in API request | N(PR), Y(PA) |
client_id | string | The client_id identifying the channel. | Y (PR,PA) |
client_secret | string | Password associated with the client_id. | Y (PR,PA) |
lob | string | The Line of Business Identifier currently available are: PREPAID POSTPAID | Y(PR), N/A(PA) |
channelId | string | Channel to business: In this case, expected channelId will be: APP (SuperApp), Qpay (RT2) Note - 'channelId' is mandatory for Mobile project | Y(PR), N/A(PA) |
targetSystem | String | This describes the end system. “Matrixx” is in scope. | Y(PR), N/A(PA) |
Query Parameter
name | type | description | required |
---|---|---|---|
publicIdentifier | string | Public identifier value of a product, like MSISDN Example:7095659489, Subscription Id Example:S-89194 Note - 'publicIdentifier' is mandatory for Mobile project | Y(PR), N/A(PA) |
publicIdentifierType | string | Public identifier type value. Aallowed values are MSISDN and SubscriptionId. Note - 'publicIdentifierType' is mandatory for Mobile project | Y(PR), N/A(PA) |
@type | string | Type of Product Note for PA: Value should be always "OTT" | Y(PA),N/A(PR) |
billingAccount.id | string | Unique identifier of the entity | Y(PA),N/A(PR) |
status | string | status of product, can be used to filter report by status Possible Values are: active, cancelled,aborted, suspended ,pendingActive | N(PA),N/A(PR) |
productSpecification.id | string | Unique product ID | N(PA),N/A(PR) |
Data Model - Response
name | type | description | required (mandatory-Y, optional-N, Not applicable- N/A, conditionallyMandatory-C/M) |
---|---|---|---|
id | string | External ID of the subscription. | N(PR), Y(PA) |
name | string | Descriptive name of subscription. | N(PR),N/A(PA) |
description | string | Is the description of the response. Hard coded as static in Mule API. | N(PR),N/A(PA) |
status | string | Status of the subscription.Example: - created - pendingActive - cancelled - active - pendingTerminate - terminated -suspended - aborted | N(PR), Y(PA) |
@type | string | The actual type of an response, @type as Subscription | N(PR ,PA) |
orderDate | datetime | Date when the product was ordered | N(PA),N/A(PR) |
startDate | datetime | Date from which the product starts | N(PA),N/A(PR) |
terminationDate | datetime | Date when the product was terminated | N(PA),N/A(PR) |
productCharacteristic | array | Describes a given characteristic of an object or entity through a name/value pair. | N(PR,PA) |
productCharacteristic.name | string | Name of the characteristic | N(PR,PA) |
productCharacteristic.value | any | The value of the characteristic | N(PR,PA) |
productCharacteristic.valueType | string | Data type of the value of the characteristic | N(PR),N/A(PA) |
relatedParty | array | Used to provide information about any other entity with relation to the operation | N(PR),N/A(PA) |
relatedParty.id | string | Subscription User unique Id at Matrixx | N(PR),N/A(PA) |
relatedParty.role | string | the role of subscription user | N(PR),N/A(PA) |
relatedParty.@type | string | Reference of subscription user | N(PR),N/A(PA) |
product | array | N(PR),N/A(PA) | |
product.id | string | Unique identifier for this offer (within subscriber/group). | N(PR),N/A(PA) |
product.name | string | External ID of product offer in pricing DB. | N(PR),N/A(PA) |
product.status | string | The offer status. | N(PR),N/A(PA) |
product.startDate | datetime | When the offer was activated. Not set if status is pre-active. If active at purchase time, ActivationTime and PurchaseTime have the same value. | N(PR),N/A(PA) |
product.orderDate | datetime | When the offer was purchased. | N(PR),N/A(PA) |
product.@type | string | type of product/offer | N(PR),N/A(PA) |
product.productOffering | object | A EntityRef is a detailed description of a bill structure. | N(PR),N/A(PA) |
product.productOffering.id | string | External ID of catalog item in pricing DB, if associated with a catalog item. I.e., not for purchased offers which are part of a bundle. | N(PR),N/A(PA) |
product.productOffering.@type | string | 'When sub-classing, this defines the sub-class entity name' | N(PR),N/A(PA) |
product.productTerm | array | N(PR),N/A(PA) | |
product.productTerm.name | string | Unique identifier for the purchased item cycle period. | N(PR),N/A(PA) |
product.productTerm.duration | object | Duration of the productTerm | N(PR),N/A(PA) |
product.productTerm.duration.amount | number | Number of periods in a purchased item cycle. | N(PR),N/A(PA) |
product.productTerm.duration.units | string | The period type. 1=Hourly, 2=Daily, 3=Weekly, 4=Monthly, 5=Yearly, 6=Minutes" | N(PR),N/A(PA) |
product.productTerm.validFor | object | productTerm validity period | N(PR),N/A(PA) |
product.productTerm.validFor.startDateTime | datetime | Start of current cycle period (latest period for which recurring processing has been attempted). | N(PR),N/A(PA) |
product.productTerm.validFor.endDateTime | datetime | End of current cycle period (latest period for which recurring processing has been attempted). | N(PR),N/A(PA) |
product.productTerm.@type | string | Reference of productTerm | N(PR),N/A(PA) |
product.productPrice | array | List of product prices | N(PR),N/A(PA) |
product.productPrice.productOfferingPrice | object | A EntityRef is a detailed description of a bill structure. | N(PR),N/A(PA) |
product.productPrice.productOfferingPrice.id | string | ID of product offer in pricing DB. | N(PR),N/A(PA) |
product.productPrice.productOfferingPrice.@type | string | Reference of ProductOfferingPrice | N(PR),N/A(PA) |
product.productCharacteristic | array | Describes a given characteristic of an object or entity through a name/value pair. | N(PR),N/A(PA) |
product.productCharacteristic.name | string | Name of the characteristic | N(PR),N/A(PA) |
product.productCharacteristic.value | any | The value of the characteristic | N(PR),N/A(PA) |
product.productCharacteristic.valueType | string | Data type of the value of the characteristic | N(PR),N/A(PA) |
product.productRelationship | array | A list of product relationships | N(PR),N/A(PA) |
product.productRelationship.relationshipType | string | Name of the relationshipType as "Parent" | N(PR),N/A(PA) |
product.productRelationship.product | object | List of child products associated with parent product | N(PR),N/A(PA) |
product.productRelationship.product.id | string | If this purchased offer was purchased as part of a bundle, this field holds the resource ID of the bundle. Otherwise the value is zero (null). | N(PR),N/A(PA) |
product.productSpecification | object | A product specification reference | N(PR),N/A(PA) |
product.productSpecification.id | string | Commercial Plan Code | N(PR),N/A(PA) |
product.productSpecification.name | string | Commercial Plan Name | N(PR),N/A(PA) |
product.productSpecification.@type | string | Product specification type | N(PR),N/A(PA) |
productSpecification | object | A product specification reference | Y(PA),N/A(PR) |
productSpecification.id | string | Unique identifier of a related entity | Y(PA),N/A(PR) |
productSpecification.name | string | Name of the related entity | N(PA),N/A(PR) |
@baseType | string | When sub-classing, this defines the super-class | N(PA),N/A(PR) |
@referredType | string | Reference of the product | N(PA),N/A(PR) |
billingAccount | string | billingAccount Reference | Y(PA), N/A(PR) |
billingAccount.id | string | billingAccount number | Y(PA), N/A(PR) |
productCharacteristic subResource - Data Model
name | type | Description | required (mandatory-Y, optional-N, Not applicable- N/A) | examples |
---|---|---|---|---|
LastActivityTime | string | This value is used for determining lifecycle inactivity trigger(s). It represents the maximum of the LastActivityUpdateTime of the subscriber and the LastActivityUpdateTime for all of the associated devices unless excluding device activity for current status definition. This field is only updated by eligible activity while in a lifecycle state which features inactivity condition(s), when transitioning status, or when the LastActivityUpdateTime is explicitly modified. | N(PR),N/A(PA) | PR: { "name": "LastActivityTime", "value": "2022-03-22T13:27:06.000000Z" } |
CurrentStatusTransitionTime | string | The time at which the subscription transitioned to the current status. | N(PR),N/A(PA) | PR: { "name": "CurrentStatusTransitionTime", "value": "2022-03-22T13:27:06.000000-04:00" } |
UserCount | string | Number of users for this subscription. | N(PR),N/A(PA) | PR: { "name": "UserCount", "value": "1" } |
statusId | string | status Id | N(PR),N/A(PA) | PR: { "name": "statusId", "value": "1" } |
LLASubType | string | LLA SubType | N(PR),N/A(PA) | PR: { "name": "LLASubType", "value": "1" } |
activationCode | string | Activation code of the product | N(PA),N/A(PR) | PA: { "name": "activationCode", "value": "270158ed-6b82-4f29-9953" } |
product.productCharacteristic subResource - Data Model
Name | type | Description | required (mandatory-Y, optional-N, Not applicable- N/A) | examples |
---|---|---|---|---|
CurrentStatusTransitionTime | string | The time at which the subscription transitioned to the current status. | N(PR),N/A(PA) | { "name": "CurrentStatusTransitionTime", "value": "2022-03-22T09:27:06.000000-04:00" } |
CycleModifyAllowed | string | If true, the cycle is configured to allow for modification. | N(PR),N/A(PA) | { "name": "CycleModifyAllowed", "value": "false" } |
OfferStatusDescription | string | Status description of the purchased offer. | N(PR),N/A(PA) | { "name": "OfferStatusDescription", "value": "active" } |
CatalogItemId | string | Catalog item ID in pricing DB, if associated with a catalog item. I.e., not for purchased offers which are part of a bundle. | N(PR),N/A(PA) | { "name": "CatalogItemId", "value": "39" } |
OfferType | string | Type of purchased offer. 1 = purchased_offer, 2 = purchased_bundle, 3 = bundle_purchased_offer Note - Mule API is doing logic, based on description making integer as string and passing to SF. | N(PR),N/A(PA) | { "name": "OfferType", "value": "purchased_bundle" } |
PrimaryBalanceResourceId | string | Resource ID of primary balance. | N(PR),N/A(PA) | { "name": "PrimaryBalanceResourceId", "value": "1" } |
AvailableAmount | string | The amount available to use based on the current active balance value. | N(PR),N/A(PA) | { "name": "AvailableAmount", "value": 637.14 } |
BalanceResourceId | string | Resource Id | N(PR),N/A(PA) | { "name": "BalanceResourceId", "value": 1 } |
Key considerations
- Please refer the examples from the following URL - DXP UX - GET Product
PA Implementation (bango usecase)::
- ‘@type’ queryParam should always be “OTT”.
- Possible values for 'status' queryParam are active, cancelled,aborted, suspended,pendingActive.
- Possible status from in the response from Bango are below mentioned
BSS Status | ESB Status | Description |
---|---|---|
ACTIVE | active | The entitlement has been successfully activated |
CANCELLED | cancelled | The entitlement has been cancelled. |
REVOKED | aborted | The entitlement has been revoked. This usually happens on fraud and user contract termination cases |
SUSPENDED | suspended | The entitlement has been suspended |
PENDING | pendingActive | The entitlement has been initiated, but the user has not yet finalized the activation process |
FAILED | FAILED | The entitlement failed |
PR Implementation::
For LCPR prepaid customers
- API returns all products/subscriptions along with status.
- We can use this API to check if the customer number(MSISDN) is active or not. In response, if payload[x].@type=subscription and payload[x].status=Active it means MSISDN is active.
Possible Error Scenarios for PA:
IF WE ARE PASSING INVALID (@type) IN QUERYPARAMS
{
"errors": [
{
"code": 400,
"message": "VALIDATION:INVALID_BOOLEAN",
"description": "Mandatory field @type is not specified or Incorrect value is received. The expected value is OTT"
}
]
}
Possible Error Scenarios for PR:
IF WE ARE PASSING INVALID (publicIdentifier) IN QUERYPARAMS
{
"errors": [
{
"code": 400,
"message": "MATRIXX:PRODUCTINVENTORY_REPORT",
"description": "11 | Subscriber not found (AccessNumber=8919414206)"
}
]
}
IF WE ARE PASSING INVALID (publicIdentifierType) IN QUERYPARAMS
{
"errors": [
{
"code": 400,
"message": "VALIDATION:MISMATCH",
"description": "PublicIdentifierType is not valid. Expected values are : SubscriptionId | MSISDN"
}
]
}
IF WE ARE PASSING INVALID CHANNELID
{
"errors": [
{
"code": 501,
"message": "LLA:NOT_IMPLEMENTED",
"description": "There is no Implementation available for this BU"
}
]
}
IF WE ARE PASSING INVALID SECURITY HEADERS
{
"error": "Invalid Client"
}