Methods to manage Service Charge data
All applications below support trusted mode, i_customer should be supplied in that mode.
createServiceCharge()
Available since version Softswitch 2025 and FreightSwitch 2025.
Adds a service charge to a service plan.
Parameters:
- i_billing_plan - Identifier of the service plan to add the charge to. Integer. Required.
- description - Service charge name/description. String. Required.
- price - Service charge price. Numeric. Required.
Returns:
- result - OK means that the service charge has been created. String.
- i_service_charge - the identifier assigned to the new service charge. Integer.
Faults:
- 400 - Service plan not found.
- 401 - A required parameter is missing or invalid.
- 402 - The Service Plan is assigned to an Account; a service charge cannot be added.
listServiceCharges()
Available since version Softswitch 2025 and FreightSwitch 2025.
Retrieves all service charges belonging to a service plan.
Parameters:
- i_billing_plan - Identifier of the service plan whose charges are listed. Integer. Required.
Returns:
- result - OK means that the service charges were retrieved successfully. String.
- assigned - whether the service plan is assigned to at least one account. Boolean.
- list - list of service charge structures ordered by identifier:
- i_service_charge - service charge identifier. Integer.
- description - service charge name/description. String.
- price - service charge price. Numeric.
Faults:
- 400 - Service plan not found.
- 401 - Missing/invalid i_billing_plan.
updateServiceCharge()
Available since version Softswitch 2025 and FreightSwitch 2025.
Updates an existing service charge. Only the supplied fields are changed; at least one editable field must be provided.
Parameters:
- i_service_charge - Identifier of the service charge to update. Integer. Required.
- description - New name/description. String. Optional.
- price - New price. Numeric. Optional.
Returns:
- result - OK means that the service charge has been updated. String.
Faults:
- 400 - No editable field was supplied (nothing to update), or the service charge was not found.
- 401 - Wrong parameter (non-integer i_service_charge, or negative price).
- 402 - The Service Plan is assigned to an Account; the price cannot be changed. Re-sending the current price is allowed.
deleteServiceCharge()
Available since version Softswitch 2025 and FreightSwitch 2025.
Deletes a service charge.
Parameters:
- i_service_charge - Identifier of the service charge to delete. Integer. Required.
Returns:
- result - OK means that the service charge has been deleted. String.
Faults:
- 400 - Service charge was not found.
- 401 - Wrong i_service_charge parameter (a non-integer value was supplied).
- 402 - The Service Plan is assigned to an Account; the service charge cannot be deleted.