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

# Duplicate Availability

> Make a copy of a Novacal availability schedule with a new name, the same timezone and the same hours.

## What the copy gets

The copy gets the same timezone and hours as the original. You give the copy a new `name`.

The copy is never the default schedule. Your default schedule does not change.

## Limits

* `name` is required. A request without it returns `422`.
* You can only duplicate schedules on your own account. Another account's schedule returns `403 access_denied`.

A successful duplicate returns `201` with the new schedule.


## OpenAPI

````yaml POST /v1/availabilities/{id}/duplicate
openapi: 3.1.0
info:
  title: Events API
  description: Public API for managing event types
  license:
    name: MIT
  version: 1.0.0
servers:
  - url: https://api.novacal.io
security:
  - bearerAuth: []
paths:
  /v1/availabilities/{id}/duplicate:
    post:
      description: >-
        Makes a copy of an availability schedule with a new name. The copy gets
        the same timezone and hours. The copy is never the default schedule.
      parameters:
        - name: id
          in: path
          description: ID of the availability schedule to duplicate
          required: true
          schema:
            type: integer
      requestBody:
        description: Name of the new schedule
        content:
          application/json:
            schema:
              type: object
              required:
                - name
              properties:
                name:
                  type: string
                  maxLength: 255
                  description: Name of the new schedule
        required: true
      responses:
        '201':
          description: Availability duplicated
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/AvailabilityResponse'
components:
  schemas:
    AvailabilityResponse:
      type: object
      required:
        - success
        - data
      properties:
        success:
          description: Indicates whether the request was successful
          type: boolean
          example: true
        data:
          $ref: '#/components/schemas/Availability'
    Availability:
      type: object
      properties:
        id:
          description: The unique identifier of the availability schedule
          type: integer
          example: 7
        name:
          description: The name of the schedule
          type: string
          example: Working hours
        timezone:
          description: IANA timezone the hours are expressed in
          type: string
          example: Europe/Belgrade
        is_default:
          description: Whether new event types get this schedule
          type: boolean
          example: true
        working_days:
          description: The weekdays the schedule is open on
          type: array
          items:
            type: string
            enum:
              - monday
              - tuesday
              - wednesday
              - thursday
              - friday
              - saturday
              - sunday
          example:
            - monday
            - tuesday
        hours:
          description: >-
            Open hours per weekday, in the schedule timezone. A weekday that is
            absent is closed.
          type: object
          additionalProperties:
            type: array
            items:
              $ref: '#/components/schemas/AvailabilityHours'
          example:
            monday:
              - start: '09:00'
                end: '17:00'
            tuesday:
              - start: '09:00'
                end: '12:00'
              - start: '14:00'
                end: '17:00'
        created_at:
          description: The date and time the schedule was created
          type: string
          format: date-time
        updated_at:
          description: The date and time the schedule was last changed
          type: string
          format: date-time
    AvailabilityHours:
      type: object
      properties:
        start:
          description: Opening time in HH:MM, in the schedule timezone
          type: string
          example: '09:00'
        end:
          description: Closing time in HH:MM, in the schedule timezone
          type: string
          example: '17:00'
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.