MENU
    Delete Employee Positions
    • 1 Minute to read
    • Dark
    • PDF

    Delete Employee Positions

    • Dark
    • PDF

    Article summary

    We have introduced a new API that allows you to delete employee positions to eliminate duplicate employee positions or inactive positions. You can delete single or multiple employee positions. When you delete employee positions, the audit log gets updated. You can use the following fields to filter the output:
    • By Scenario
    • By Home Budget Entity
    • By Employee
    • By Employee and Position Description

    Method
    POST

    Endpoint Url Syntax
    /Position/DeleteEmployeesAndPositions

    Content Type
    application/json

    Headers

    KeyValue
    APIKeyKey

    Example1
    Request

    {
    				"EmployeeFilterOptions": "EmployeePositions",
    				"ScenarioCode": "Workforce-FY21",
    				"EmployeeData" :
    				[
    				["HYD004","P1","SDE"],
    				["HYD003","P1","P2"]
    
    				]
    				}
    Plain text

    Reponse

    {
    				"Status": "Failure",
    				“ScenarioCode": "Workforce-FY21"
    				"DeleteEmployeesResult": [
    				{
    				"Key": "HYD004",
    				"Values": [
    				"Employee Number HYD004 is invalid."
    				]
    				},
    				{
    				"Key": "HYD003",
    				"Values": [
    				"P1 does not exist for Employee HYD003",
    				"P2 does not exist for Employee HYD003"
    				]
    				}
    				]
    				}
    Plain text

    Example2
    **Request
    **

    {
    				"EmployeeFilterOptions": "EmployeePositions",
    				"ScenarioCode": "Workforce-FY21",
    				"EmployeeData" :
    				[
    				["HYD002","SDE"],
    				["HYD003","SDE","P2"]
    
    				]
    				}
    Plain text

    Reponse

    {
    				"Status": "PartialSuccess",
    				“ScenarioCode": "Workforce-FY21"
    				"DeleteEmployeesResult": [
    				{
    				"Key": "HYD003",
    				"Values": [
    				"P2 does not exist for Employee HYD003",
    				"Employee Position SDE deleted successfully."
    				]
    				},
    				{
    				"Key": "HYD002",
    				"Values": [
    				"Employee Position SDE deleted successfully."
    				]
    				}
    				]
    				}
    Plain text

    Example3
    Request

    {
    				"EmployeeFilterOptions": "Employees",
    				"ScenarioCode": "Workforce-FY21",
    				"EmployeeData" :
    				[
    				["HYD002"],
    				["HYD003"]
    
    				]
    				}
    Plain text

    Reponse

    {
    				"Status": "Failure",
    				“ScenarioCode": "Workforce-FY21"
    				"DeleteEmployeesResult": [
    				{
    				"Key": "HYD002",
    				"Values": [
    				"Employee Number HYD002 is invalid."
    				]
    				},
    				{
    				"Key": "HYD003",
    				"Values": [
    				"Employee Number HYD003 is invalid."
    				]
    				}
    				]
    				}
    Plain text

    Example4
    Request

    {
    				"EmployeeFilterOptions": "Employees",
    				"ScenarioCode": "Workforce-FY21",
    				"EmployeeData" :
    				[
    				["HYD005"],
    				["HYD006"]
    
    				]
    				}
    Plain text

    Reponse

    {
    "Status": "PartialSuccess",
    “ScenarioCode": "Workforce-FY21"
    "DeleteEmployeesResult": [
    {
    "Key": "HYD006",
    "Values": [
    "Employee Number HYD006 is invalid."
    ]
    },
    {
    "Key": "HYD005",
    "Values": [
    "Employee deleted successfully."
    ]
    }
    ]
    }
    Plain text

    Example5
    **Request
    **

    {
    				"EmployeeFilterOptions": "HomeBudgetEntities",
    				"ScenarioCode": "Workforce-FY21",
    				"EmployeeData" :
    				[
    				["Hbe1"],
    				["Hbe2"]
    
    				]
    				}
    Plain text

    Reponse

    {
    				"Status": "Failure",
    				“ScenarioCode": "Workforce-FY21"
    				"DeleteEmployeesResult": [
    				{
    				"Key": "HomeBudgetEntities",
    				"Values": [
    				"Please provide a value for </BE>."
    					]
    					}
    					]
    					}
    Plain text

    Example6
    Request

    {
    				"EmployeeFilterOptions": "HomeBudgetEntities",
    				"ScenarioCode": "Workforce-FY21",
    				"HomeBudgetEntityCode" :
    				["1000","HBE01"]
    
    				}
    Plain text

    Reponse

    {
    				"Status": "PartialSuccess",
    				“ScenarioCode": "Workforce-FY21"
    				"DeleteEmployeesResult": [
    				{
    				"Key": "HBE01",
    				"Values": [
    				"Home Budget entity Code HBE01 is invalid."
    				]
    				},
    				{
    				"Key": "1000",
    				"Values": [
    				"Employee(s) deleted successfully."
    				]
    				}
    				]
    				}
    Plain text

    Was this article helpful?