AVAILABLE WITH BUSINESS SUBSCRIPTION

Request: POST /user/{userId}/scheduled_termination

Permissions to Run the Request

Account Owner, Account Administrators, Department Administrators, or custom roles

Department Administrators and users with a custom role may set up a scheduled end of employment only for users belonging to the departments they manage or their daughter departments. 

Request Headers

Header

Description

Authorization (required)Access token. You can obtain a token by making a request.
ParameterDescription
userId (required)The ID of a user you want to set up a scheduled end of employment for.
date (required)The date when employment will end for a user in the yyyy-mm-dd format, for example, 2023-12-27.

Possible Response Codes

Code

Text

Description

200OKThe date of scheduled end of employment is set.
400Bad RequestA request error.
401UnauthorizedAn authorization error.
403Permission DeniedThe user doesn't have enough permissions.

 

Sample Request

POST /api/v2/user/{userid}/scheduled_termination HTTP/1.1 
Host: api-learn.ispringlearn.com 
Authorization: p-1sJDjmULL5DdpXPJTcbm4jVIaWVHvNmrjAxATRbNE

<?xml version="1.0" encoding="UTF-8"?>
<request>
    <date>2023-12-27</date>
</request>
XML

Sample Response

https/1.1 200 OK
XML