Skip to main content
Skip table of contents

Addon plan API with validity and subscription

The addon plan API changes will be available as from the release 4.13.0 in April 2024.

FAQs

What are the API changes?

We are adding new functionalities on the addon plans.

Specifically you can define

  • the validity of the benefits

  • the expiration of the benefits

  • and re-subscriptions rules

Are there also going to be UI changes? How the addons changes look like?

Below how the Subscriptions and Validity will work.

The new Subscriptions and Validity menu will be visible.

image-20240321-114135.png

New menus available

image-20240321-113929.png

New Subscription menu

image-20240321-114011.png

New Validity Menu

What will happen to my existing addons

They will be automatically converted in the new version

We continue to support the old functionalities and only adding new ones. So old Addons will continue to work as normal.

Which APIs will be affected?

The following APIs will be affected by the Addon changes

These plan APIs have many use cases, are they all affected?

No.

Only the cases that are relevant for Addon Plan are affected.

For example, if you are using Plan - Create to create a new Base plan, then there are no changes

But if you are using it to create new Addon Plan, the old API calls will not work since they will be missing some parameters.

Same for the Plan - Modify and Query Rate Plan,

How to identify that its an Addon Plan?

Those that have planCategory = ADDON

I am NOT using these APIs for addon plans. Will my current API calls still work?

Yes.

I am using these APIs for managing addon plans. What i need to know?
  • There are few parameters the we have removed. You can still use them in your API calls but they will be ignored.

  • There is one parameter that we have moved inside an array

  • There are some new parameters that we have added

For more details see the Addons Old vs New examples below.

Is there an API versioning for these API changes?

No. In this case it was not possible to implement a versioning of the APIs due to the nature of the changes.

Is there a sandbox to test the new API calls?

No.

But in order for you to prepare the changes, we have published a DEVELOPER preview API documentation with examples that you can check:

Link: API DOCUMENTATION - DEV REL 4.13

API Old versus New

Plan - Create:

OLD API CALL

CODE
{
	"Request": {
		"plan": {
			"basicInfo": {
				"planName": "ADDONOLD",
				"planType": "1",
				"planCategory": "ADDON",
				"planDescription": "Postpaid ADDON PLAN",
				"serviceProfile": "SP_007",
				"planStatus": "Active",
				"currencyId": "44",
				"destinationGroup": "007" ,
				"addOnPriority": "2",
				"activatedBy": "1"			==> This is MOVED
			},
			"benefit": [
				{
					"benefitId": "1994",
					"value": "10",
					"action": "0",		==> This is Removed. If you provide it is ignored
					"rateZone": "5093"
				}
			],
			"charge": [
				{
					"chargeId": "9",	==> !!! This is Removed. API will fail if you provide it.
					"factor": "1",		==> This is Removed. If you provide it is ignored
					"frequency": "2",	==> This is Removed. If you provide it is ignored
					"autoRenewal": "true",	==> This is Removed. If you provide it is ignored
					"chargeAmount": "1"
				}
			]
		}
	}
}

NEW API CALL

CODE
{
    "Request":{
      "plan": {
        "basicInfo": {
				"planName": "ADDONNEW",
		    	"planType": "1",                      
				"planCategory": "ADDON",
				"planDescription": "PostpaidADDON PLAN",
				"serviceProfile": "SP_007",
				"planStatus": "Active",
				"currencyId": "44",
				"destinationGroup": "007" ,
				"addOnPriority": "2"

			},
			"benefit": [
				{
					"benefitId": "1",
					"value": "10",

				    "rateZone": "5093"
				}
			],
			"charge": [
				{


		

					"chargeAmount": "3434"
				}
				],
            "subscription":                 ==> NEW Parameters
				{	
					"reSubscription": "true",
					"reSubscriptionRule":"2",
					"occurrences":"10000",
					"activatedBy": "1"
				},
            "validity":                      ==> NEW Parameters
				{	
					"validityType":"1",
					"validityFactor":"44"
				}					
				
		}
	}
}

Plan - Modify:

OLD API CALL

CODE
{  
   "Request":{  
      "plan":{  
         "basicInfo":{  
            "planId":"007"
         },
         "charge":[  
            {  
               "chargeId":"8",  ==> !!! This is Removed. API will fail if you provide it.
              "chargeAmount":"40"
            }
      ],
      "benefit": [
                {
                    "benefitId": "001",
                    "value": "10",
                    "action": "0",
                    "rateZone": "123"
                }
      ]
      }
   }
}

NEW API CALL

CODE
{
    "Request": {
        "plan": {
            "basicInfo": {
                "planId": "007"
            },
            "charge": [
                {
                
                    "chargeAmount": "40"
                }
            ],
            "benefit": [
                {
                    "benefitId": "001",
                    "value": "10",
                    "action": "0",
                    "rateZone": "123"
                }
            ]   
            "subscription": {                 ==> NEW Parameters
                "reSubscription": "true",
                "reSubscriptionRule": "1",
                "occurrences": "1",
                "activatedBy": "0"
            },
            "validity": {                     ==> NEW Parameters
                "validityType": "1",
                "validityFactor": "1"
            }
            
        }
    }
}

Query Rate Plan

OLD API CALL

CODE
{
    "Response": {
        "responseId": "46678177428123275",
        "responseTimestamp": "13/05/2020 12:13:55",
        "resultCode": "0",
        "resultParam": {
            "resultCode": "1056",
            "resultDescription": "Query rate plan success"
        },
        "responseParam": {
            "plan": [
                {
                    "basicInfo": {
                        "planId": "007",
                        "planName": "ADDONOLD",
                        "cugEnabled": "false",
                        "planDescription": "Postpaid ADDON PLAN",
                        "planType": "1",
                       "serviceId": "9|5|2",
                        "planCategory": "ADDON",
                        "planAmount": "343400",
                        "planEffectiveDate": "04/03/2024 07:47:23",
                        "planExpiryDate": "31/12/2099 00:00:00",
                        "productId": "1",
                        "productName": "PREPAID",
                        "serviceIdName": "SMS|NB-IOT|DATA",
                        "planTypeName": "Prepaid",
                        "createdBy": "32135101",
                        "networkTypeName": "GSM",
                        "networkTypeId": "1",
                        "currency": "44",
                        "revertedPlanAmount": "3434",
                        "status": "Active",
                        "currencyMainUnitId": "4",
                        "currencyMainUnitSymbol": "EUR",
                        "saleTypeId": "1",
                        "saleTypeName": "Wholesale",
                        "destGroupId": "12345",
                        "destGroupName": "Destinationall",
                        "profileId": "SP_007",
                        "addOnPriority": "1"
                    },
                    "serviceProfile": {
                        "profileId": "SP_304",
                        "profileName": "AddonServiceProfile",
                        "serviceCategory": "1",
                        "networkTypeId": "1",
                        "createdBy": "31170383",
                        "service": "2|9",
                        "accessVarientId": "4|2|3",
                        "ratType": "08",
                        "feature": [
                            {
                                "featureId": "3",
                                "featureName": "DATA",
                                "columnName": "IsGPRSAllowed",
                                "featureHLRName": "DATA",
                                "type": "M",
                                "defaultFeatures": "IsGPRSAllowed=true|IsRoamingDataAllowed=true",
                                "value": "true"
                            }
                        ]
                    },
                    "chargeInfo": [
                        {
                            "chargeId": "9",	==> This is Removed. 
							"factor": "1",		==> This is Removed. 
							"frequency": "2",	==> This is Removed. 
							"autoRenewal": "true",	==> This is Removed. 
							"chargeAmount": "1"
                        }
                    ],
                    "benefits": [
                        {
                            "benefitId": "1994",
                            "benefitName": "DATA_POSTPAID",
                            "unitType": "Mb",
                            "benefit": "10",
                            "type": "VOLUME",
                            "rateZone": "5093"
                        }
                    ]
                },
            ],
            "totalCount": "1"
        }
    }
}

NEW API CALL

CODE
{
    "Response": {
        "responseId": "13299182484573797",
        "responseTimestamp": "14/03/2024 07:24:36",
        "resultCode": "0",
        "resultParam": {
            "resultCode": "1056",
            "resultDescription": "Query rate plan success"
        },
        "responseParam": {
            "plan": [
                {
                    "basicInfo": {
                        "planId": "007",
                        "planName": "ADDONNEW",
                        "cugEnabled": "false",
                        "planDescription": "PostpaidADDON PLAN",
                        "planType": "1",
                        "serviceId": "9|5|2",
                        "planCategory": "ADDON",
                        "planAmount": "343400",
                        "planEffectiveDate": "04/03/2024 07:47:23",
                        "planExpiryDate": "31/12/2099 00:00:00",
                        "productId": "1",
                        "productName": "PREPAID",
                        "serviceIdName": "SMS|NB-IOT|DATA",
                        "planTypeName": "Prepaid",
                        "createdBy": "32135101",
                        "networkTypeName": "GSM",
                        "networkTypeId": "1",
                        "currency": "44",
                        "revertedPlanAmount": "3434",
                        "status": "Active",
                        "currencyMainUnitId": "4",
                        "currencyMainUnitSymbol": "EUR",
                        "saleTypeId": "1",
                        "saleTypeName": "Wholesale",
                        "destGroupId": "12345",
                        "destGroupName": "Destinationall",
                        "profileId": "SP_007",
                        "addOnPriority": "1"
                    },
                    "serviceProfile": {
                        "profileId": "SP_66248",
                        "profileName": "Serviceaddon",
                        "serviceCategory": "1",
                        "networkTypeId": "1",
                        "createdBy": "32135101",
                        "service": "9|5|2",
                        "accessVarientId": "2|5|4",
                        "ratType": "10",
                        "feature": [
                            {
                                "featureId": "13",
                                "featureName": "NB-IOT",
                                "columnName": "IsNBIOT",
                                "featureHLRName": "RADIO_ACCESS_NB_IOT",
                                "type": "M",
                                "defaultFeatures": "IsNBIOT=true",
                                "value": "true"
                            }
                        ]
                    },
                    "chargeInfo": [
                        {
                         
                         
                    
                         
                            "chargeAmount": "1"
                        }
                    ],
                    "benefits": [
                        {
                            "benefitId": "1",
                            "benefitName": "DATA",
                            "unitType": "Mb",
                            "benefit": "10",
                            "type": "VOLUME",
                            "rateZone": "5093"
                        }
                    ],
                    "subscription": {               ==> NEW Parameters
                        "reSubscription": "true",
                        "reSubscriptionRule": "2",
                        "occurrences": "2",
                        "activatedBy": "1"
                    },
                    "validity": {                   ==> NEW Parameters
                        "validityType": "1",
                        "validityTypeName": "Daily",
                        "validityFactor": "44"
                    }
                }
            ],
            "totalCount": "1"
        }
    }
}

Update 2024/04/02

  • Corrected a type on Query Rate Plan - NEW API CALL: validityType instead of validityTypeID

  • Update for “chargeId” on Plan - Create and Plan - Modify: API will fail if it us used

JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.