Astrocal Availability API

The Availability API from Astrocal — 2 operation(s) for availability.

Operations 3

PUT /v1/event-types/{id}/availability Set availability rules for an event type #
GET /v1/event-types/{id}/availability Get availability rules for an event type #
GET /v1/availability Query available booking slots #

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/astrocal-dev:astrocal-dev-availability-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

astrocal-dev-availability-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: Astrocal Availability API
  version: 1.0.0
  description: Scheduling API for AI agents and developers
servers:
- url: https://api.astrocal.dev
  description: Production
- url: https://api.astrocal.dev
  description: Local development
security:
- BearerAuth: []
tags:
- name: Availability
paths:
  /v1/event-types/{id}/availability:
    put:
      tags:
      - Availability
      summary: Set availability rules for an event type
      description: Replaces all availability rules for an event type. Rules define recurring weekly time windows when the event type can be booked. Pass an empty `rules` array to clear all availability.
      parameters:
      - schema:
          type: string
          format: uuid
        required: true
        name: id
        in: path
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                rules:
                  type: array
                  items:
                    type: object
                    properties:
                      day_of_week:
                        type: integer
                        minimum: 0
                        maximum: 6
                      start_time:
                        type: string
                        pattern: ^([01]\d|2[0-3]):[0-5]\d:[0-5]\d$
                      end_time:
                        type: string
                        pattern: ^([01]\d|2[0-3]):[0-5]\d:[0-5]\d$
                    required:
                    - day_of_week
                    - start_time
                    - end_time
                timezone:
                  type: string
                  minLength: 1
              required:
              - rules
              - timezone
      responses:
        '200':
          description: Availability rules updated
          content:
            application/json:
              schema:
                type: object
                properties:
                  event_type_id:
                    type: string
                    format: uuid
                  timezone:
                    type: string
                  rules:
                    type: array
                    items:
                      type: object
                      properties:
                        id:
                          type: string
                          format: uuid
                        event_type_id:
                          type: string
                          format: uuid
                        day_of_week:
                          type: integer
                        start_time:
                          type: string
                        end_time:
                          type: string
                        created_at:
                          type: string
                      required:
                      - id
                      - event_type_id
                      - day_of_week
                      - start_time
                      - end_time
                      - created_at
                required:
                - event_type_id
                - timezone
                - rules
        '401':
          description: Unauthorized
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: object
                    properties:
                      code:
                        type: string
                      message:
                        type: string
                      details:
                        type: object
                        additionalProperties:
                          nullable: true
                    required:
                    - code
                    - message
                required:
                - error
        '404':
          description: Not found
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: object
                    properties:
                      code:
                        type: string
                      message:
                        type: string
                      details:
                        type: object
                        additionalProperties:
                          nullable: true
                    required:
                    - code
                    - message
                required:
                - error
        '422':
          description: Validation error
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: object
                    properties:
                      code:
                        type: string
                      message:
                        type: string
                      details:
                        type: object
                        additionalProperties:
                          nullable: true
                    required:
                    - code
                    - message
                required:
                - error
      operationId: putV1EventTypesByIdAvailability
      x-operation-id-source: derived
    get:
      tags:
      - Availability
      summary: Get availability rules for an event type
      description: Returns the current availability rules and timezone for an event type. Use the public availability endpoint to query computed bookable slots.
      parameters:
      - schema:
          type: string
          format: uuid
        required: true
        name: id
        in: path
      responses:
        '200':
          description: Availability rules
          content:
            application/json:
              schema:
                type: object
                properties:
                  event_type_id:
                    type: string
                    format: uuid
                  timezone:
                    type: string
                  rules:
                    type: array
                    items:
                      type: object
                      properties:
                        id:
                          type: string
                          format: uuid
                        event_type_id:
                          type: string
                          format: uuid
                        day_of_week:
                          type: integer
                        start_time:
                          type: string
                        end_time:
                          type: string
                        created_at:
                          type: string
                      required:
                      - id
                      - event_type_id
                      - day_of_week
                      - start_time
                      - end_time
                      - created_at
                required:
                - event_type_id
                - timezone
                - rules
        '401':
          description: Unauthorized
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: object
                    properties:
                      code:
                        type: string
                      message:
                        type: string
                      details:
                        type: object
                        additionalProperties:
                          nullable: true
                    required:
                    - code
                    - message
                required:
                - error
        '404':
          description: Not found
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: object
                    properties:
                      code:
                        type: string
                      message:
                        type: string
                      details:
                        type: object
                        additionalProperties:
                          nullable: true
                    required:
                    - code
                    - message
                required:
                - error
      operationId: getV1EventTypesByIdAvailability
      x-operation-id-source: derived
  /v1/availability:
    get:
      tags:
      - Availability
      summary: Query available booking slots
      description: Public endpoint — no authentication required. Returns available time slots for an event type within a date range.
      parameters:
      - schema:
          type: string
          format: uuid
        required: true
        name: event_type_id
        in: query
      - schema:
          type: string
          pattern: ^\d{4}-\d{2}-\d{2}$
        required: true
        name: start
        in: query
      - schema:
          type: string
          pattern: ^\d{4}-\d{2}-\d{2}$
        required: true
        name: end
        in: query
      - schema:
          type: string
          minLength: 1
        required: true
        name: timezone
        in: query
      - schema:
          type: string
          format: uuid
        required: false
        name: host_id
        in: query
      - schema:
          type: integer
          minimum: 5
          maximum: 480
        required: false
        name: duration
        in: query
      responses:
        '200':
          description: Available slots
          content:
            application/json:
              schema:
                type: object
                properties:
                  event_type_id:
                    type: string
                    format: uuid
                  timezone:
                    type: string
                  start:
                    type: string
                  end:
                    type: string
                  slots:
                    type: array
                    items:
                      type: object
                      properties:
                        start_time:
                          type: string
                        end_time:
                          type: string
                        spots_remaining:
                          type: integer
                        total_capacity:
                          type: integer
                        available:
                          type: boolean
                        waitlist_available:
                          type: boolean
                        waitlist_position:
                          type: integer
                      required:
                      - start_time
                      - end_time
                  capped:
                    type: boolean
                  waitlist_available:
                    type: boolean
                  waitlist_position:
                    type: integer
                required:
                - event_type_id
                - timezone
                - start
                - end
                - slots
        '400':
          description: Bad request (invalid timezone or date range)
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: object
                    properties:
                      code:
                        type: string
                      message:
                        type: string
                      details:
                        type: object
                        additionalProperties:
                          nullable: true
                    required:
                    - code
                    - message
                required:
                - error
        '404':
          description: Event type not found
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: object
                    properties:
                      code:
                        type: string
                      message:
                        type: string
                      details:
                        type: object
                        additionalProperties:
                          nullable: true
                    required:
                    - code
                    - message
                required:
                - error
        '422':
          description: Validation error
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: object
                    properties:
                      code:
                        type: string
                      message:
                        type: string
                      details:
                        type: object
                        additionalProperties:
                          nullable: true
                    required:
                    - code
                    - message
                required:
                - error
        '429':
          description: Rate limit exceeded
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: object
                    properties:
                      code:
                        type: string
                      message:
                        type: string
                      details:
                        type: object
                        additionalProperties:
                          nullable: true
                    required:
                    - code
                    - message
                required:
                - error
      operationId: getV1Availability
      x-operation-id-source: derived
components:
  securitySchemes:
    BearerAuth:
      type: http
      scheme: bearer
      description: API key authentication. Use your API key as the bearer token.