Service Types API

7 PracBill API endpoints for service types. Base URL https://billing.pracbill.com.au/api.

Create a new service type

POST /{api_key}/serviceType/add

Request body

FieldTypeDescription
typeofservice requiredstringName of the service type (required)
activebooleanWhether the service type is active and offered in lists/selectors (defaults to true)
ratecodestringInternal rate code
list_pricenumberDefault ex-tax list price
cost_pricenumberEx-tax cost price
wholesale_pricenumberWholesale price for resellers
reseller_pricenumberReseller price
invoice_typestringInvoice type this service belongs to
calls_serviceinteger (0 | 1)Whether this is a call-based service (0 or 1)
data_serviceinteger (0 | 1)Whether this is a data service (0 or 1)
data_unlimitedinteger (0 | 1)Whether data is unlimited (0 or 1)
data_included_mbintegerIncluded data in MB
helpdesk_displayinteger (0 | 1)Display in helpdesk module (0 or 1)
reporting_categorystringCategory for reporting purposes
vidintegerVendor/Supplier ID
vendor_product_idstringVendor's product identifier
allow_orderinteger (0 | 1)Allow ordering through Orders module (0 or 1)
call_typesarray of integerArray of call type IDs allowed for this service
default_call_typesarray of integerArray of default call type IDs for billing

Responses

  • 200 — Service type created successfully
  • 400 — Bad request - missing required fields or invalid data

Delete a service type. Will fail if there are active services associated with this service type.

DELETE /{api_key}/serviceType/delete/{esid}

Responses

  • 200 — Service type deleted successfully
  • 400 — Cannot delete - active services exist
  • 404 — Service type not found

Retrieve filtered service types without pagination

POST /{api_key}/serviceType/filter/get

Request body

FieldTypeDescription
helpdesk_displaybooleanwhether this service type displays in the helpdesk module
invoice_typestringThe invoice type that the service type is displaye don
calls_servicebooleanIf this is a call based service
sms_postpaidbooleanIf this is a sms postpaid service
data_servicebooleanIf this is a data service
data_unlimitedbooleanUnlimited Data included?
data_included_mbintegerNumber of MB included in the service, for the filter, this is an exact match and has no ability for > or < or any wilcards
vidintegerVendor or Supplier ID
vendor_product_idstringVendor's Product ID
ratecodestringThe rate code for types
data_service_technologystringWhat type of data technologies
data_service_typestringwhat data service types are available
allow_orderbooleanIf the service is allowed to be ordered through the orders module
activebooleanFilter by active state. Defaults to true (active only) when neither this nor include_inactive is supplied
include_inactivebooleanSet to true to return both active and inactive service types (ignored when `active` is supplied)
typeofservicestringA wildcard search for type of service

Responses

  • 200 — Request received successfully

POST /{api_key}/serviceType/filter/get/page/{page_number}

POST /{api_key}/serviceType/filter/get/page/{page_number}

Request body

FieldTypeDescription
helpdesk_displaybooleanwhether this service type displays in the helpdesk module
invoice_typestringThe invoice type that the service type is displaye don
calls_servicebooleanIf this is a call based service
sms_postpaidbooleanIf this is a sms postpaid service
data_servicebooleanIf this is a data service
data_unlimitedbooleanUnlimited Data included?
data_included_mbintegerNumber of MB included in the service, for the filter, this is an exact match and has no ability for > or < or any wilcards
vidintegerVendor or Supplier ID
vendor_product_idstringVendor's Product ID
ratecodestringThe rate code for types
data_service_technologystringWhat type of data technologies
data_service_typestringwhat data service types are available
allow_orderbooleanIf the service is allowed to be ordered through the orders module
activebooleanFilter by active state. Defaults to true (active only) when neither this nor include_inactive is supplied
include_inactivebooleanSet to true to return both active and inactive service types (ignored when `active` is supplied)
typeofservicestringA wildcard search for type of service

Responses

  • 200 — Request received successfully

Retrieve a paginated list of service types and basic information. Only active service types are returned unless include_inactive is set.

GET /{api_key}/serviceType/get/page/{page_number}

Responses

  • 200 — Request received successfully

Get detailed information about a specific service type

GET /{api_key}/serviceType/get/{esid}

Responses

  • 200 — Request received successfully
  • 404 — Service type not found

Update an existing service type

POST /{api_key}/serviceType/update/{esid}

Request body

FieldTypeDescription
typeofservicestringName of the service type
activebooleanWhether the service type is active and offered in lists/selectors
ratecodestringInternal rate code
list_pricenumberDefault ex-tax list price
cost_pricenumberEx-tax cost price
wholesale_pricenumberWholesale price for resellers
reseller_pricenumberReseller price
invoice_typestringInvoice type this service belongs to
calls_serviceinteger (0 | 1)Whether this is a call-based service (0 or 1)
data_serviceinteger (0 | 1)Whether this is a data service (0 or 1)
data_unlimitedinteger (0 | 1)Whether data is unlimited (0 or 1)
data_included_mbintegerIncluded data in MB
helpdesk_displayinteger (0 | 1)Display in helpdesk module (0 or 1)
reporting_categorystringCategory for reporting purposes
vidintegerVendor/Supplier ID
vendor_product_idstringVendor's product identifier
allow_orderinteger (0 | 1)Allow ordering through Orders module (0 or 1)
call_typesarray of integerArray of call type IDs allowed for this service
default_call_typesarray of integerArray of default call type IDs for billing

Responses

  • 200 — Service type updated successfully
  • 404 — Service type not found

← All API groups