removeUsersFromSupplementalPayPeriod
curl --request POST \
--url https://sandbox.rollfi.xyz/payroll/removeUsersFromSupplementalPayPeriod \
--header 'Authorization: Basic <encoded-value>' \
--header 'Content-Type: application/json' \
--data '
{
"method": "removeUsersFromSupplementalPayPeriod",
"companyId": "C8D57032-BF6F-4510-AA41-08A358365531",
"payPeriodId": "4083B766-8F3A-4A23-ABB7-FB67FA1F97D3",
"payrollLineItems": [
{
"userId": "7DDB8A83-29D5-4454-9467-53CC80307139",
"reason": ""
}
]
}
'import requests
url = "https://sandbox.rollfi.xyz/payroll/removeUsersFromSupplementalPayPeriod"
payload = {
"method": "removeUsersFromSupplementalPayPeriod",
"companyId": "C8D57032-BF6F-4510-AA41-08A358365531",
"payPeriodId": "4083B766-8F3A-4A23-ABB7-FB67FA1F97D3",
"payrollLineItems": [
{
"userId": "7DDB8A83-29D5-4454-9467-53CC80307139",
"reason": ""
}
]
}
headers = {
"Authorization": "Basic <encoded-value>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Basic <encoded-value>', 'Content-Type': 'application/json'},
body: JSON.stringify({
method: 'removeUsersFromSupplementalPayPeriod',
companyId: 'C8D57032-BF6F-4510-AA41-08A358365531',
payPeriodId: '4083B766-8F3A-4A23-ABB7-FB67FA1F97D3',
payrollLineItems: [{userId: '7DDB8A83-29D5-4454-9467-53CC80307139', reason: ''}]
})
};
fetch('https://sandbox.rollfi.xyz/payroll/removeUsersFromSupplementalPayPeriod', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://sandbox.rollfi.xyz/payroll/removeUsersFromSupplementalPayPeriod",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'method' => 'removeUsersFromSupplementalPayPeriod',
'companyId' => 'C8D57032-BF6F-4510-AA41-08A358365531',
'payPeriodId' => '4083B766-8F3A-4A23-ABB7-FB67FA1F97D3',
'payrollLineItems' => [
[
'userId' => '7DDB8A83-29D5-4454-9467-53CC80307139',
'reason' => ''
]
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Basic <encoded-value>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://sandbox.rollfi.xyz/payroll/removeUsersFromSupplementalPayPeriod"
payload := strings.NewReader("{\n \"method\": \"removeUsersFromSupplementalPayPeriod\",\n \"companyId\": \"C8D57032-BF6F-4510-AA41-08A358365531\",\n \"payPeriodId\": \"4083B766-8F3A-4A23-ABB7-FB67FA1F97D3\",\n \"payrollLineItems\": [\n {\n \"userId\": \"7DDB8A83-29D5-4454-9467-53CC80307139\",\n \"reason\": \"\"\n }\n ]\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Basic <encoded-value>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://sandbox.rollfi.xyz/payroll/removeUsersFromSupplementalPayPeriod")
.header("Authorization", "Basic <encoded-value>")
.header("Content-Type", "application/json")
.body("{\n \"method\": \"removeUsersFromSupplementalPayPeriod\",\n \"companyId\": \"C8D57032-BF6F-4510-AA41-08A358365531\",\n \"payPeriodId\": \"4083B766-8F3A-4A23-ABB7-FB67FA1F97D3\",\n \"payrollLineItems\": [\n {\n \"userId\": \"7DDB8A83-29D5-4454-9467-53CC80307139\",\n \"reason\": \"\"\n }\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://sandbox.rollfi.xyz/payroll/removeUsersFromSupplementalPayPeriod")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Basic <encoded-value>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"method\": \"removeUsersFromSupplementalPayPeriod\",\n \"companyId\": \"C8D57032-BF6F-4510-AA41-08A358365531\",\n \"payPeriodId\": \"4083B766-8F3A-4A23-ABB7-FB67FA1F97D3\",\n \"payrollLineItems\": [\n {\n \"userId\": \"7DDB8A83-29D5-4454-9467-53CC80307139\",\n \"reason\": \"\"\n }\n ]\n}"
response = http.request(request)
puts response.read_body{
"payrollLineItems": [
{
"userId": "7DDB8A83-29D5-4454-9467-53CC80307139",
"status": "Removed",
"message": "The PayrollLineItem for Const Jonas has been removed successfully."
}
]
}{
"error": {
"code": 400,
"message": "UserId is mandatory"
}
}Payroll
removeUsersFromSupplementalPayPeriod
The removeUsersFromSupplementalPayPeriod API is used to remove employees from a supplemental pay period after they have been added.
When to use:
- When correcting supplemental payroll mistakes before submission
- When removing accidental bonus or adjustment entries
Notes:
- Cannot remove all employees - at least one must remain
- If you wish to remove all employees, instead use the
skipPayPeriodAPI.
POST
/
payroll
/
removeUsersFromSupplementalPayPeriod
removeUsersFromSupplementalPayPeriod
curl --request POST \
--url https://sandbox.rollfi.xyz/payroll/removeUsersFromSupplementalPayPeriod \
--header 'Authorization: Basic <encoded-value>' \
--header 'Content-Type: application/json' \
--data '
{
"method": "removeUsersFromSupplementalPayPeriod",
"companyId": "C8D57032-BF6F-4510-AA41-08A358365531",
"payPeriodId": "4083B766-8F3A-4A23-ABB7-FB67FA1F97D3",
"payrollLineItems": [
{
"userId": "7DDB8A83-29D5-4454-9467-53CC80307139",
"reason": ""
}
]
}
'import requests
url = "https://sandbox.rollfi.xyz/payroll/removeUsersFromSupplementalPayPeriod"
payload = {
"method": "removeUsersFromSupplementalPayPeriod",
"companyId": "C8D57032-BF6F-4510-AA41-08A358365531",
"payPeriodId": "4083B766-8F3A-4A23-ABB7-FB67FA1F97D3",
"payrollLineItems": [
{
"userId": "7DDB8A83-29D5-4454-9467-53CC80307139",
"reason": ""
}
]
}
headers = {
"Authorization": "Basic <encoded-value>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Basic <encoded-value>', 'Content-Type': 'application/json'},
body: JSON.stringify({
method: 'removeUsersFromSupplementalPayPeriod',
companyId: 'C8D57032-BF6F-4510-AA41-08A358365531',
payPeriodId: '4083B766-8F3A-4A23-ABB7-FB67FA1F97D3',
payrollLineItems: [{userId: '7DDB8A83-29D5-4454-9467-53CC80307139', reason: ''}]
})
};
fetch('https://sandbox.rollfi.xyz/payroll/removeUsersFromSupplementalPayPeriod', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://sandbox.rollfi.xyz/payroll/removeUsersFromSupplementalPayPeriod",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'method' => 'removeUsersFromSupplementalPayPeriod',
'companyId' => 'C8D57032-BF6F-4510-AA41-08A358365531',
'payPeriodId' => '4083B766-8F3A-4A23-ABB7-FB67FA1F97D3',
'payrollLineItems' => [
[
'userId' => '7DDB8A83-29D5-4454-9467-53CC80307139',
'reason' => ''
]
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Basic <encoded-value>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://sandbox.rollfi.xyz/payroll/removeUsersFromSupplementalPayPeriod"
payload := strings.NewReader("{\n \"method\": \"removeUsersFromSupplementalPayPeriod\",\n \"companyId\": \"C8D57032-BF6F-4510-AA41-08A358365531\",\n \"payPeriodId\": \"4083B766-8F3A-4A23-ABB7-FB67FA1F97D3\",\n \"payrollLineItems\": [\n {\n \"userId\": \"7DDB8A83-29D5-4454-9467-53CC80307139\",\n \"reason\": \"\"\n }\n ]\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Basic <encoded-value>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://sandbox.rollfi.xyz/payroll/removeUsersFromSupplementalPayPeriod")
.header("Authorization", "Basic <encoded-value>")
.header("Content-Type", "application/json")
.body("{\n \"method\": \"removeUsersFromSupplementalPayPeriod\",\n \"companyId\": \"C8D57032-BF6F-4510-AA41-08A358365531\",\n \"payPeriodId\": \"4083B766-8F3A-4A23-ABB7-FB67FA1F97D3\",\n \"payrollLineItems\": [\n {\n \"userId\": \"7DDB8A83-29D5-4454-9467-53CC80307139\",\n \"reason\": \"\"\n }\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://sandbox.rollfi.xyz/payroll/removeUsersFromSupplementalPayPeriod")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Basic <encoded-value>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"method\": \"removeUsersFromSupplementalPayPeriod\",\n \"companyId\": \"C8D57032-BF6F-4510-AA41-08A358365531\",\n \"payPeriodId\": \"4083B766-8F3A-4A23-ABB7-FB67FA1F97D3\",\n \"payrollLineItems\": [\n {\n \"userId\": \"7DDB8A83-29D5-4454-9467-53CC80307139\",\n \"reason\": \"\"\n }\n ]\n}"
response = http.request(request)
puts response.read_body{
"payrollLineItems": [
{
"userId": "7DDB8A83-29D5-4454-9467-53CC80307139",
"status": "Removed",
"message": "The PayrollLineItem for Const Jonas has been removed successfully."
}
]
}{
"error": {
"code": 400,
"message": "UserId is mandatory"
}
}Authorizations
Basic authentication header of the form Basic <encoded-value>, where <encoded-value> is the base64-encoded string username:password.
Body
application/json
Response
Show child attributes
Show child attributes
⌘I
