REST API Documentation
Malta Salary Calculator API
Use this API to calculate Malta gross salary, tax, social security contribution, COLA bonus, and estimated net pay.
Available Endpoints
GET
/salary/health
GET
/salary/options
POST
/salary/calculate
POST
/salary/batch
Base URL
https://themaltasalarycalculator.com/api
Health Check
Check API Status
GET /salary/health
Example Response
{
"success": true,
"message": "Malta salary calculator API is running."
}
Options
Get Supported Options
GET /salary/options
Example Response
{
"success": true,
"data": {
"marital_status": ["Single", "Married", "Parent"],
"children_count": [0, 1, 2],
"booleans": ["is_student", "is_18_plus", "is_before_1962"],
"default_hours_per_week": 40,
"supported_input_currency": "EUR",
"cola": {
"weekly": 9.86,
"monthly": 42.71,
"yearly": 512.52
}
}
}
Main Endpoint
Calculate Salary
POST /salary/calculate
Request Parameters
| Field | Type | Required | Description |
|---|---|---|---|
| annual_gross_salary | number | Required | Annual gross salary in EUR. |
| marital_status | string | Optional | Single, Married, or Parent. Default is Single. |
| children_count | integer | Optional | 0, 1, or 2. Use 2 for 2 or more children. |
| is_student | boolean | Optional | Whether student SSC rates should be applied. |
| is_18_plus | boolean | Optional | Whether the employee is over 18 years old. Default is true. |
| is_before_1962 | boolean | Optional | Whether the employee was born before 1962. |
| hours_per_week | number | Optional | Used for hourly calculation. Default is 40. |
| target_currency | string | Optional | Example: USD, GBP, PKR, AED. Default currency is EUR. |
| exchange_rate | number | Optional | Required only when target_currency is not EUR. |
Example Request
{
"annual_gross_salary": 30000,
"marital_status": "Single",
"children_count": 0,
"is_student": false,
"is_18_plus": true,
"is_before_1962": false,
"hours_per_week": 40
}
Example Response
{
"success": true,
"data": {
"input": {
"annual_gross_salary": 30000,
"marital_status": "Single",
"children_count": 0,
"is_student": false,
"is_18_plus": true,
"is_before_1962": false,
"hours_per_week": 40
},
"currency": "EUR",
"gross_pay": {
"hourly": 15.63,
"weekly": 625,
"monthly": 2500,
"yearly": 30000
},
"ssc_ni": {
"hourly": 1.4,
"weekly": 55.93,
"monthly": 223.72,
"yearly": 2684.64
},
"tax": {
"hourly": 1.71,
"weekly": 68.75,
"monthly": 275,
"yearly": 3300
},
"cola_bonus": {
"hourly": 0.25,
"weekly": 9.86,
"monthly": 42.71,
"yearly": 512.52
},
"net_pay": {
"hourly": 12.51,
"weekly": 500.32,
"monthly": 2001.28,
"yearly": 24015.36
}
}
}
Batch Calculation
Calculate Multiple Salaries
POST /salary/batch
Example Request
{
"items": [
{
"annual_gross_salary": 30000,
"marital_status": "Single"
},
{
"annual_gross_salary": 45000,
"marital_status": "Married",
"children_count": 1
}
]
}
Example Response
{
"success":true,
"data":[
{
"input":{
"annual_gross_salary":30000,
"marital_status":"Single",
"children_count":0,
"is_student":false,
"is_18_plus":true,
"is_before_1962":false,
"hours_per_week":40
},
"currency":"EUR",
"gross_pay":{
"hourly":15.63,
"weekly":625,
"monthly":2500,
"yearly":30000
},
"ssc_ni":{
"hourly":1.4,
"weekly":55.93,
"monthly":223.72,
"yearly":2684.64
},
"tax":{
"hourly":2.14,
"weekly":85.42,
"monthly":341.67,
"yearly":4100
},
"cola_bonus":{
"hourly":0.25,
"weekly":9.86,
"monthly":42.71,
"yearly":512.52
},
"net_pay":{
"hourly":12.09,
"weekly":483.65,
"monthly":1934.61,
"yearly":23215.36
}
},
{
"input":{
"annual_gross_salary":45000,
"marital_status":"Married",
"children_count":1,
"is_student":false,
"is_18_plus":true,
"is_before_1962":false,
"hours_per_week":40
},
"currency":"EUR",
"gross_pay":{
"hourly":23.44,
"weekly":937.5,
"monthly":3750,
"yearly":45000
},
"ssc_ni":{
"hourly":1.4,
"weekly":55.93,
"monthly":223.72,
"yearly":2684.64
},
"tax":{
"hourly":3.11,
"weekly":124.48,
"monthly":497.92,
"yearly":5975
},
"cola_bonus":{
"hourly":0.25,
"weekly":9.86,
"monthly":42.71,
"yearly":512.52
},
"net_pay":{
"hourly":18.93,
"weekly":757.09,
"monthly":3028.36,
"yearly":36340.36
}
}
]
}