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

# Create webhook

> Create a webhook for the current workspace. The webhook will receive events for the specified topics.



## OpenAPI

````yaml /api/openapi.json post /webhooks
openapi: 3.1.0
info:
  title: Ordinal API
  version: 1.0.0
  description: API to create and manage Ordinal workspaces, posts, profiles, and analytics
servers:
  - url: https://app.tryordinal.com/api/v1
    description: Production server
security:
  - bearerAuth: []
tags:
  - name: Analytics
    description: Social media analytics data
  - name: Approvals
    description: Post approval workflows
  - name: Comments
    description: >-
      Post comments for team collaboration. Supports @mentions using the format
      @[Display Name](userId).
  - name: Engagements
    description: Auto-engagements for posts (likes, comments, reposts)
  - name: Invites
    description: Workspace invitations for adding new users
  - name: Labels
    description: Labels for organizing posts
  - name: Instagram
    description: Instagram utilities for location search and tagging
  - name: LinkedIn
    description: LinkedIn utilities for profile lookups, tagging, and mentions
  - name: Posts
    description: Create and manage posts
  - name: Profiles
    description: List connected social profiles
  - name: Slack Boosts
    description: >-
      List connected Slack channels (webhooks), then create and manage slack
      boosts so teams get notified in Slack when posts publish. Requires Slack
      connected with marketing boost channels.
  - name: Subscribers
    description: Post subscribers for notifications
  - name: File Uploads
    description: >-
      Upload files from URLs for use in posts. Supports images (JPEG, PNG, GIF,
      WebP) up to 10 MB and videos (MP4, MOV) up to 350 MB.
  - name: Ideas
    description: >-
      Create and manage content ideas. Ideas are draft posts without scheduled
      dates that can be converted to calendar posts.
  - name: Inline Comments
    description: >-
      Text-anchored comments on specific post content. Read-only API for
      retrieving inline comments across channels.
  - name: Users
    description: Workspace users
  - name: Webhooks
    description: >-
      Create, list, get, update, and delete webhooks to receive real-time event
      notifications
  - name: Workspaces
    description: Workspace information
paths:
  /webhooks:
    post:
      tags:
        - Webhooks
      summary: Create webhook
      description: >-
        Create a webhook for the current workspace. The webhook will receive
        events for the specified topics.
      operationId: webhooks-create
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              required:
                - name
                - url
                - topics
              properties:
                name:
                  type: string
                  description: The name of the webhook
                url:
                  type: string
                  format: uri
                  description: The URL that will receive webhook events
                description:
                  type: string
                  description: An optional description for the webhook
                topics:
                  type: array
                  items:
                    type: string
                    enum:
                      - social_profile.connected
                      - social_profile.disconnected
                      - social_profile.reconnect_needed
                      - post.created
                      - post.scheduled
                      - post.rescheduled
                      - post.unscheduled
                      - post.published
                      - post.publish_failed
                      - post.archived
                      - post.permanently_deleted
                      - post.content.edited
                      - post.comment.created
                      - post.inline_comment.created
                      - post.approval.requested
                      - post.approval.approved
                      - campaign.approval.requested
                      - campaign.approval.approved
                      - invite.created
                      - invite.accepted
                  minItems: 1
                  description: The event types this webhook should listen to
                headers:
                  type: object
                  additionalProperties:
                    type: string
                  description: Optional custom headers to include in webhook requests
            example:
              name: CRM Sync
              url: https://example.com/webhooks/ordinal
              description: Sync published posts to our CRM
              topics:
                - post.published
                - post.archived
      responses:
        '200':
          description: Webhook created
          content:
            application/json:
              schema:
                type: object
                properties:
                  id:
                    type: string
                    format: uuid
                  name:
                    type: string
                  url:
                    type: string
                    format: uri
                  topics:
                    type: array
                    items:
                      type: string
                  createdAt:
                    type: string
                    format: date-time
              example:
                id: 550e8400-e29b-41d4-a716-446655440900
                name: CRM Sync
                url: https://example.com/webhooks/ordinal
                topics:
                  - post.published
                  - post.archived
                createdAt: '2026-01-15T10:00:00.000Z'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
components:
  responses:
    BadRequest:
      description: Bad Request - Invalid input parameters
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ValidationError'
          example:
            code: BAD_REQUEST
            message: Bad Request
            data:
              errors:
                publishAt:
                  - Invalid date format
                status:
                  - Invalid enum value
    Unauthorized:
      description: Unauthorized - Missing or invalid API key
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
          example:
            code: UNAUTHORIZED
            message: Invalid or unauthorized API key
  schemas:
    ValidationError:
      type: object
      properties:
        code:
          type: string
        message:
          type: string
        data:
          type: object
          properties:
            errors:
              type: object
              additionalProperties:
                type: array
                items:
                  type: string
    Error:
      type: object
      properties:
        code:
          type: string
        message:
          type: string
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: >-
        API key authentication. Generate an API key from your workspace
        settings.

````