Thanks to visit codestin.com
Credit goes to www.scribd.com

0% found this document useful (0 votes)
16 views5 pages

Failed Query Provision v1.1

This document outlines the API for retrieving failed provisioning information for communication partners (CPs). It includes details on the API endpoint, request headers, parameters, and response formats, as well as examples of requests and responses. Additional guidelines for processing failed provisioning records and handling specific scenarios are also provided.

Uploaded by

mydala.subhps
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
16 views5 pages

Failed Query Provision v1.1

This document outlines the API for retrieving failed provisioning information for communication partners (CPs). It includes details on the API endpoint, request headers, parameters, and response formats, as well as examples of requests and responses. Additional guidelines for processing failed provisioning records and handling specific scenarios are also provided.

Uploaded by

mydala.subhps
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 5

Version No.

Date Changed By Changes


1.0 Dec 16, 2021 Anita Paudel Final Draft
1.1 Feb 2, 2022 Anita Paudel Updates

1
Introduction
This API provides the failed provisioning information to the CPs. CPs can trigger this API to get failed
provisioning data. This API returns failed provisioning end point related data array as response. The
array of response contains internal notification from consent system to SDP which should be ignored by
the partners.

Failed notification Info API Summary

1. API Endpoint

GET {{baseURL}}/pns-sdp-queryfailedprovinfo/v1.0/scm/failed_provisioning_info

{{baseURL}} will be provided separately.

2. Request Details

2.1 Request Header

Header Required Type Values / Description


Accept Mandatory String Application/json
Content-Type Mandatory String application/json
Authorization Mandatory Base64 Bearer <access token for the api store
Encoded String application>

Note: You will get this token from


Generate/Refresh Token API. Please refresh and
provide the valid one as access token will be
expired upon generation.
Range Mandatory String No. of records to be pulled.
Format is X-Y where X is Offset and Y is Number
of records to be pulled. Y should be limited to
100.
Samples Values
Range: 0-5
➔ provides record starting from first record to
next 5 records
Range: 99-50
➔ provides record starting from 100th record
to next 50 records

2.2 Request Parameters

Parameter Required Type Values / Description


partner Mandatory Integer Partner ID as provided by Ncell
from_time Mandatory Date Start date of query in format YYYY-MM-DD
to_time Mandatory Date End date of query in format YYYY-MM-DD

2
2.3 Response Parameters

Parameter Required Type Values / Description


Response Status 200 (Ok), 400 (Bad Request), 401 (Unauthorized), 403
(Forbidden), 415 (Unsupported Media Type), 409
(Conflict), 500 (Internal Server Error)

Response Body A status object (). Failed provision record arrays within the
specified requested range of the provided date
url Optional String Provisioning URL where failure occurred
Service_code Optional String Service code for which failure occurred
request_data Optional String Data sent in provisioning request
prov_type Optional String action values
partner_id Optional String Partner ID as provided by Ncell

Example Request

curl -XGET <base URL>/scm/failed_provisioning_info?partner_id=2&from_time=2021-11-


30&to_time=2021-12-07' --header 'Content-Type: application/json' --header 'Accept: application/json' -
-header 'Authorization: Bearer f3ff8810-29d8-396c-aa41-xxyyzzzvvv --header 'Range: 0-2'

Example Response
1. Successful Sample
HTTP/1.1 200 OK Content-Type: application/json

[{
"url": "https://callback.com/LPBase/callback/2000964_42902",
"status_flag": 0,
"service_code": "XXYYZZXGAMES1Y30",
"request_data":
"?msisdn=97798XXXXXXXX&status=0&service_code=XXYYZZXGAMES1Y30&description=Session
%20info%20expired&request_id=mzW7YSuY&action=150&channel=105&partner_id=XX",
"prov_type": "150",
"protocol": "172",
"partner_id": XX,
"msisdn": "97798XXXXXXXX",
"created_dttm": "2021-12-01 06:10:11"
},
{
"url": "https://callback.com/LPBase/callback/2000964_42902",
"status_flag": 0,
"service_code": "XXYYZZXGAMES1Y30",

3
"request_data":
"?msisdn=977980884XXXX&status=0&service_code=XXYYZZXGAMES1Y30&description=Session
%20info%20expired&request_id=uS9CYoZA&action=150&channel=105&partner_id=XX",
"prov_type": "150",
"protocol": "172",
"partner_id": XX,
"msisdn": "977980884XXXX",
"created_dttm": "2021-12-01 06:10:21"
}
]

2. Sample case when no records


{
"status": 404,
"message": "Not found"
}

Additional Info:
1. The records that are only failed provision to provider URL only need to be processed. URL
parameter in response body should be used for this.
2. Range should be limited to 100 numbers per query.
3. The polling should be scheduled every hour. Each polling request should fetch not more than
100 records until the status message of 404 not found is received in each hour.
4. Logic to be implemented in case of following scenario:

Unsubscription request received without subscription request beforehand

Description
Product un-subscription notification request is received, and product subscription request is not
received due to partner endpoint not being accessible or partner endpoint sending failure /
reject.
Product Type: Installment / Renewal
Assumption: Failed Query Provision API is deployed to get failed provision request.
Recommended process
1. Record the received unsubscription request.
2. Send the next failed query provision API request (immediate or scheduled)
3. Match the failed query request with unsubscription request (MSISDN + service code +
expiry date)
a. In case of action = 150 and status = 1 [ Non Trial Period ], the service should be
continued for remaining days of expiry date i.e. Expiry date > unsubscription request
date
b. In case of action = 159 and status = 1 [ Trial Period ], the service should be
discontinued.

4
5

You might also like