> ## Documentation Index
> Fetch the complete documentation index at: https://specbeeconsultingservices.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# POST Leave Request

> Create a leave request. This endpoint is currently in alpha and should not be used by default. Only TILT managed requests can have a status other than PENDING.



## OpenAPI

````yaml post /platform/api/leave_requests
openapi: 3.0.0
info:
  title: API Reference
  version: '1.0'
  contact:
    name: Rippling Support
    email: support@rippling.com
  license:
    name: MIT
  description: >-
    Using Rippling's API requires either an API key or an access token retrieved
    from an OAuth exchange. Each is tied to a single Rippling Company.


    If you are a partner building an integration to Rippling,you can use
    [Rippling's Installation
    Guide](https://developer.rippling.com/docs/rippling-api/fucwnbc121hiu-installation-guide)
    to learn how to retrieve an access token to start using Rippling APIs.


    If you are a customer, you can go
    [here](https://developer.rippling.com/docs/rippling-api/9rw6guf819r5f-introduction-for-customers)
    to learn create your API keys to start using Rippling APIs.


    ### Using the Interactive Documentation


    Rippling's Documentation Portal allows you to test the API endpoints
    directly within the documentation. To do so, provide your API key or Access
    Token as a header parameter with the form Authorization Bearer: Bearer.
  termsOfService: https://app.rippling.com/developer/tos
servers:
  - url: https://api.rippling.com
    description: Production
security:
  - Token: []
tags:
  - name: A. Companies
  - name: B. Employees
  - name: C. Payroll
  - name: D. 401k
  - name: F. Groups
  - name: G. SAML
  - name: E. Current User
  - name: H. ATS
  - name: I. Application Management
  - name: J. Reports
  - name: Deprecated
paths:
  /platform/api/leave_requests:
    parameters: []
    post:
      tags:
        - J. Leaves
      summary: POST Leave Request
      description: >-
        Create a leave request. This endpoint is currently in alpha and should
        not be used by default. Only TILT managed requests can have a status
        other than PENDING.
      operationId: post-leave_requests
      requestBody:
        content:
          application/json:
            schema:
              type: object
              required:
                - role
                - startDate
                - endDate
                - companyLeaveType
                - leavePolicy
              properties:
                role:
                  type: string
                  description: Unique identifier of the employee who is taking leave.
                requestedBy:
                  type: string
                status:
                  type: string
                  x-stoplight:
                    id: v5a9k7lkpbeln
                  description: >-
                    The status to create the leave request in. Only TILT managed
                    requests can take a status other than PENDING.
                startDate:
                  type: string
                endDate:
                  type: string
                startDateStartTime:
                  type: string
                endDateEndTime:
                  type: string
                startDateCustomHours:
                  type: string
                endDateCustomHours:
                  type: string
                companyLeaveType:
                  type: string
                  description: Unique identifier of the company leave type
                leavePolicy:
                  type: string
                  description: >-
                    Unique identifier of the leave policy. Required if request
                    is not managed by TILT
                reasonForLeave:
                  type: string
                managedBy:
                  type: string
                  description: >-
                    String identifier for third party that manages this leave
                    request. This may be null.
                externalId:
                  type: string
                  description: >-
                    Object id for corresponding leave obejct in third party
                    system. This may be null.
            examples:
              New LeaveRequest:
                value:
                  role: 5ae0b2cb40cae73202bd66cc
                  status: PENDING
                  startDate: '2018-08-22'
                  endDate: '2018-08-24'
                  startDateStartTime: '2018-08-22T12:00:00.235000-07:00'
                  endDateEndTime: '2018-08-24T15:00:00.235000-07:00'
                  startDateCustomHours: '8'
                  endDateCustomHours: '4'
                  reasonForLeave: Visiting hometown for my brother’s wedding
                  companyLeaveType: 4c397f3b3c304e478da575da
                  leavePolicy: 5b998cf940cae798a83e87fd
      responses:
        '201':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/LeaveRequest'
              examples:
                Success:
                  value:
                    - id: 5b998dfb40cae798a83e8874
                      createdAt: '2018-08-12T15:06:51.681000-07:00'
                      updatedAt: '2018-08-13T15:06:51.684000-07:00'
                      role: 5ae0b2cb40cae73202bd66cc
                      roleName: Jane Doe
                      requestedBy: 5ae0b2cb40cae73202bd66cc
                      requestedByName: Jane Doe
                      status: PENDING
                      startDate: '2018-08-22'
                      endDate: '2018-08-24'
                      startDateStartTime: '2018-08-22T12:00:00.235000-07:00'
                      endDateEndTime: '2018-08-24T15:00:00.235000-07:00'
                      startDateCustomHours: 8
                      endDateCustomHours: 4
                      comments: null
                      numHours: 20
                      numMinutes: 1200
                      leavePolicy: 5b998cf940cae798a83e87fd
                      leaveType: VACATION
                      policyDisplayName: Vacation
                      processedAt: null
                      processedBy: null
                      processedByName: null
                      reasonForLeave: Visiting hometown for my brother’s wedding
                      externalId: qwerty12345
                      roleTimezone: America/Los_Angeles
                      dates:
                        - date: '2018-08-22'
                          numMinutes: 480
                        - date: '2018-08-23'
                          numMinutes: 480
                        - date: '2018-08-24'
                          numMinutes: 240
      security:
        - Token: []
components:
  schemas:
    LeaveRequest:
      title: LeaveRequest
      type: object
      description: Leave request object.
      x-tags:
        - Models
      properties:
        id:
          type: string
          description: Unique identifier of the leave request.
        createdAt:
          type: string
        updatedAt:
          type: string
        role:
          type: string
          description: Unique identifier of the employee who is taking leave.
        roleName:
          type: string
        requestedBy:
          type: string
          nullable: true
        requestedByName:
          type: string
          description: >-
            Unique identifier of the employee who made the request (in most
            cases this is the same as role).
          nullable: true
        status:
          type: string
          enum:
            - PENDING
            - APPROVED
            - REJECTED
            - CANCELED
        startDate:
          type: string
        endDate:
          type: string
        startDateStartTime:
          type: string
          nullable: true
        endDateEndTime:
          type: string
          nullable: true
        startDateCustomHours:
          type: string
          nullable: true
        endDateCustomHours:
          type: string
          nullable: true
        comments:
          type: string
          nullable: true
        numHours:
          type: integer
          nullable: true
        numMinutes:
          type: integer
          nullable: true
        leavePolicy:
          type: string
        leaveTypeUniqueId:
          type: string
          enum:
            - VACATION
            - SICK
            - JURY_DUTY
          x-stoplight:
            id: 5027t5htx71ca
        policyDisplayName:
          type: string
        reasonForLeave:
          type: string
          nullable: true
        processedAt:
          type: string
          nullable: true
        processedBy:
          type: string
          description: >-
            Unique identifier of the employee who approved or rejected the
            request. This may be null.
          nullable: true
        processedByName:
          type: string
          nullable: true
        roleTimezone:
          type: string
          description: >-
            Timezone of the role. This will be work location timezone, or home
            timezone for employees without a work location.
          nullable: true
        dates:
          type: array
          items:
            type: object
            properties:
              date:
                type: string
                format: date
              numMinutes:
                type: integer
        isPaid:
          type: boolean
          description: >-
            If the leave request is paid this will be TRUE. Otherwise, this will
            be FALSE.
          x-stoplight:
            id: kpec0dv84c37r
        managedBy:
          type: string
          x-stoplight:
            id: kpec0dv84c37r
          enum:
            - PTO
            - LEAVES
            - TILT
          description: >-
            This indicates the system that manages the Leave Request. PTO =
            managed by Rippling's Time Off app. LEAVES = managed by Rippling's
            Leave Management app. TILT = managed by third-party partner Tilt.
        partialDays:
          type: array
          x-stoplight:
            id: j5hp2dwf5fq4x
          items:
            x-stoplight:
              id: 3blh0wzzsznnx
            type: object
            nullable: true
            properties:
              partialDay:
                type: string
                x-stoplight:
                  id: x3jcwqkp9dmzu
                format: date
              numMinutes:
                type: integer
                x-stoplight:
                  id: a5rt8hxcn4yww
  securitySchemes:
    Token:
      type: http
      scheme: bearer

````