# Dify.ai Custom Tool Bundle for Reeling (OpenAPI 3.0.3)
# Import in Dify Studio -> Tools -> Custom -> Create Custom Tool -> Import from URL:
# https://reeling.app/.well-known/openapi.json
openapi: 3.0.3
info:
  title: Reeling Social & Community Publisher
  version: 1.1.0
  description: Publish across 15 social channels, discover Reddit/Quora questions, check spam/shadowban scores, and generate AI video storyboards.
servers:
  - url: https://api.reeling.app/api/v1
paths:
  /projects:
    get:
      operationId: listProjects
      summary: List Reeling workspaces and project IDs
      responses:
        "200":
          description: Projects list
  /channels:
    get:
      operationId: listChannels
      summary: List connected social channels for a project
      parameters:
        - name: projectId
          in: query
          required: false
          schema:
            type: string
      responses:
        "200":
          description: Connected channels
  /community/discover:
    post:
      operationId: discoverCommunityQuestions
      summary: Discover fresh Reddit and Quora questions for target topics
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              required: [topics]
              properties:
                topics:
                  type: array
                  items:
                    type: string
                platforms:
                  type: array
                  items:
                    type: string
      responses:
        "200":
          description: Discovered questions and cadence quota
  /community/draft-answer:
    post:
      operationId: draftCommunityAnswer
      summary: Draft a non-promotional answer and compute a 0-100 Spam Safety Score
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              required: [platform, questionTitle]
              properties:
                platform:
                  type: string
                questionTitle:
                  type: string
                questionUrl:
                  type: string
                expertiseContext:
                  type: string
      responses:
        "200":
          description: Drafted answer and spamSafety score
  /publish:
    post:
      operationId: publishPost
      summary: Schedule or publish video, text, or community posts across 15 networks
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              required: [project_id, platforms]
              properties:
                project_id:
                  type: string
                title:
                  type: string
                caption:
                  type: string
                video_url:
                  type: string
                reply_to_url:
                  type: string
                scheduled_for:
                  type: string
                platforms:
                  type: array
                  items:
                    type: string
      responses:
        "200":
          description: Publication result
