Get Upgradeable Plans¶
Endpoint¶
GET /api/v1/subscriber/getUpgradeablePlans
This endpoint retrieves a list of plans that the authenticated subscriber can upgrade to.
Authorization¶
- Type: Bearer Token
- Header:
Authorization: Bearer <your_token_here>
Example Request¶
curl -X GET "https://yourispcrmdomain/api/v1/subscriber/getUpgradeablePlans" \
-H "Authorization: Bearer YOURAPITOKENHERE"
Response¶
Success Response (200 OK)¶
{
"success": true,
"data": [
{
"plan_id": 2,
"name": "Premium Plan",
"price": 50.00,
"speed": "200Mbps",
"description": "High-speed plan for heavy users"
},
{
"plan_id": 3,
"name": "Ultra Plan",
"price": 75.00,
"speed": "500Mbps",
"description": "Ultra-fast plan for power users"
}
]
}
Explanation: - success - Indicates if the request was successful. - data - An array of upgradeable plans: - plan_id - Unique ID of the plan. - name - Name of the plan. - price - Monthly cost of the plan. - speed - Internet speed offered. - description - Brief description of the plan.
Error Responses¶
404 Not Found¶
{
"success": false,
"message": "Customer not found"
}
Explanation: - This error occurs if the subscriber cannot be found.
422 Validation Error¶
{
"success": false,
"message": "Validation error occurred"
}
Explanation: - This error occurs if the request parameters are invalid.
Example Response¶
{
"success": true,
"data": [
{
"plan_id": 2,
"name": "Premium Plan",
"price": 50.00,
"speed": "200Mbps",
"description": "High-speed plan for heavy users"
},
{
"plan_id": 3,
"name": "Ultra Plan",
"price": 75.00,
"speed": "500Mbps",
"description": "Ultra-fast plan for power users"
}
]
}
For further assistance, contact our support team at support@netgroot.com.