Docs home

Get Calculate Fees Template for Course

Calculates the instalments a learner would pay for a course under a fee template: amounts, due dates, discount from a promo code and GST. Use it on a checkout page before enrollment.

GET/calculatesplit
Get Calculate Fees Template for Course
curl --request GET \
  --url 'https://<your-api-host>/nuSource/api/v1/calculatesplit?institution_bundle_id=<institutionBundleId>&template_id=<templateId>'
{
  "code": 200,
  "message": "Success",
  "payment_split": {
    "institution_bundle_id": "503",
    "template_id": "302",
    "package_due_date": "19/05/2022",
    "expiration_after": 0,
    "currency_original_cost": 10,
    "original_cost": 10,
    "currency_symbol": "₹",
    "organization_base_currency": 49,
    "currency_id": 49,
    "rate": "1.00000",
    "num_of_decimals": 2,
    "position": 1,
    "adjustment_rate": "0.00000",
    "package_cost_set": 1,
    "promocode_discount": 0,
    "organization_id": 417,
    "payment_splits": [
      {
        "instalment_name": "Full Payment",
        "currency_symbol": "₹",
        "position": 1,
        "part_amount": 10,
        "part_date": 1652918400,
        "part_formatted_date": "19/05/2022",
        "discount": 0,
        "final_amount": 10
      }
    ]
  }
}

Access: Public, no API key.

Query parameters
institution_bundle_idintegerrequired
Course listing ID.
template_idintegerrequired
Fee template (from "Get Fees Template by Organization ID"). Must be offered for this course.
Promo code to apply. Letters and digits only.
Batch, when the template is set per batch. Default 0.
Currency to price in. Defaults to the organization's display currency.
date_of_admissionUnix timestamp
Enrollment date that due dates count from. Default today.
Response200application/json
codeinteger
Example: 200
messagestring
Example: Success
Show child attributesHide child attributes
Example: 302
Last due date, dd/mm/yyyy
Example: 19/05/2022
Example: 10
Example: 49
Example: 1.00000
Example: 1
Example: 0.00000
Show child attributesHide child attributes
Unix timestamp
Example: 1652918400
Dd/mm/yyyy, India time
Example: 19/05/2022

Notes: GST applies only to INR prices when the institute has GST on; IGST or CGST+SGST is chosen from the caller's location. Errors: "Package cost is not set in branch's base currency." and "Something went wrong." (template not offered for this course). Rate limit: 30 requests per minute; going over locks you out for 30 minutes.

Updated yesterday

Ask AI