{
  "openapi": "3.1.0",
  "info": {
    "title": "Postcrow",
    "version": "0.4.0",
    "description": "Schedule and publish social posts for one or many brands. The same tools as the Postcrow MCP server (https://postcrow.app/api/mcp), as plain HTTP. Authenticate with an API key from Settings: Authorization: Bearer psk_... The HTTP API and the MCP server are part of the Pro, Agency and Platform plans; outgoing webhooks (see webhooks below, managed with postcrow_webhooks) are part of Platform."
  },
  "servers": [
    {
      "url": "https://postcrow.app"
    }
  ],
  "components": {
    "schemas": {},
    "securitySchemes": {
      "bearerAuth": {
        "type": "http",
        "scheme": "bearer"
      }
    }
  },
  "security": [
    {
      "bearerAuth": []
    }
  ],
  "paths": {
    "/api/v1/tools/postcrow_network_rules": {
      "post": {
        "operationId": "postcrow_network_rules",
        "summary": "Network rules",
        "description": "Every network Postcrow can publish to, in short: whether it is open for connection on this server, its text limit (and the shorter limit with media), how many images and videos it takes, whether it requires a video, and whether the first line becomes the title. For the full detail of the networks...",
        "x-openai-isConsequential": false,
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {},
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The tool result as JSON.",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "400": {
            "description": "Invalid arguments."
          },
          "401": {
            "description": "Missing or invalid API key."
          },
          "402": {
            "description": "The HTTP API is part of the paid plans (Pro, Agency, Platform); the body carries upgrade_url."
          },
          "429": {
            "description": "Rate limited."
          }
        }
      }
    },
    "/api/v1/tools/postcrow_platform_constraints": {
      "post": {
        "operationId": "postcrow_platform_constraints",
        "summary": "Platform constraints",
        "description": "Read this before adapting content. For each network connected on a brand (or the networks you name): text limit and how it is counted, media kinds, formats and sizes, the fields it accepts and the ones it requires (title, body formats, excerpt, featured image, tag caps, draft or scheduled status,...",
        "x-openai-isConsequential": false,
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "project_id": {
                    "type": "string",
                    "description": "Project (brand) UUID from postcrow_list_projects. If omitted, the user's first project is used."
                  },
                  "platforms": {
                    "type": "array",
                    "items": {
                      "type": "string",
                      "enum": [
                        "facebook",
                        "instagram",
                        "linkedin",
                        "twitter",
                        "telegram",
                        "dailymotion",
                        "mastodon",
                        "discord",
                        "bluesky",
                        "youtube",
                        "tiktok",
                        "threads",
                        "pinterest",
                        "reddit",
                        "devto",
                        "hashnode",
                        "snapchat",
                        "peertube",
                        "kick",
                        "twitch",
                        "tumblr",
                        "wordpress",
                        "wordpress_self",
                        "ghost",
                        "blogger",
                        "hatena",
                        "vimeo",
                        "soundcloud",
                        "deviantart",
                        "flickr",
                        "meetup",
                        "nextdoor",
                        "band",
                        "weibo",
                        "letterboxd"
                      ]
                    },
                    "description": "Networks to describe. Default: the ones connected on the brand."
                  }
                },
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The tool result as JSON.",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "400": {
            "description": "Invalid arguments."
          },
          "401": {
            "description": "Missing or invalid API key."
          },
          "402": {
            "description": "The HTTP API is part of the paid plans (Pro, Agency, Platform); the body carries upgrade_url."
          },
          "429": {
            "description": "Rate limited."
          }
        }
      }
    },
    "/api/v1/tools/postcrow_publish_article": {
      "post": {
        "operationId": "postcrow_publish_article",
        "summary": "Publish an article",
        "description": "Publish one long article to blogs (WordPress.com, self-hosted WordPress, Ghost, Blogger, Hatena Blog): title, body in Markdown or HTML, excerpt, featured image, tags, and whether the blog publishes it, keeps it as a draft, or publishes it at publish_at. Postcrow sends it at scheduled_at, in the n...",
        "x-openai-isConsequential": true,
        "parameters": [
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional, 1 to 255 visible ASCII characters (a UUID). A retry with the same key within 24 hours returns the first answer (header Idempotent-Replayed: true) instead of running again.",
            "schema": {
              "type": "string",
              "maxLength": 255
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "project_id": {
                    "type": "string",
                    "description": "Project (brand) UUID from postcrow_list_projects. If omitted, the user's first project is used."
                  },
                  "platforms": {
                    "type": "array",
                    "minItems": 1,
                    "items": {
                      "type": "string",
                      "enum": [
                        "wordpress",
                        "wordpress_self",
                        "ghost",
                        "blogger",
                        "hatena"
                      ]
                    },
                    "description": "Blogs connected on the brand."
                  },
                  "title": {
                    "type": "string"
                  },
                  "body": {
                    "type": "string",
                    "description": "The article. Up to 200000 characters."
                  },
                  "body_format": {
                    "type": "string",
                    "enum": [
                      "markdown",
                      "html",
                      "text"
                    ],
                    "description": "Default markdown. Hatena reads the body in the blog's own mode."
                  },
                  "excerpt": {
                    "type": "string"
                  },
                  "featured_image": {
                    "type": "string",
                    "description": "Public https URL. Uploaded to WordPress and Ghost, linked on Blogger."
                  },
                  "tags": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    },
                    "description": "Tags without the #. Caps per network: postcrow_platform_constraints."
                  },
                  "network_status": {
                    "type": "string",
                    "enum": [
                      "publish",
                      "draft",
                      "scheduled"
                    ],
                    "description": "What the blog does with it. Default publish."
                  },
                  "publish_at": {
                    "type": "string",
                    "format": "date-time",
                    "description": "With network_status scheduled: when the blog publishes it."
                  },
                  "scheduled_at": {
                    "type": "string",
                    "format": "date-time",
                    "description": "When Postcrow sends it, ISO 8601 with offset. Omit for a Postcrow draft."
                  },
                  "queue": {
                    "type": "boolean",
                    "description": "Put it in the brand's next free posting slot instead of scheduled_at."
                  },
                  "per_network": {
                    "type": "object",
                    "description": "Per-network versions, keyed by network id: a short text for X and a full article for WordPress in the same post. Each network only accepts the fields it reads (postcrow_platform_constraints lists them); others are refused with the reason.",
                    "additionalProperties": {
                      "type": "object",
                      "properties": {
                        "content": {
                          "type": "string",
                          "description": "This network's own text, instead of the shared content."
                        },
                        "media_urls": {
                          "type": "array",
                          "items": {
                            "type": "string"
                          },
                          "description": "This network's own media, instead of the shared media_urls."
                        },
                        "title": {
                          "type": "string",
                          "description": "Article, video, track, photo or deviation title."
                        },
                        "body": {
                          "type": "string",
                          "description": "Article body (blogs)."
                        },
                        "body_format": {
                          "type": "string",
                          "enum": [
                            "markdown",
                            "html",
                            "text"
                          ],
                          "description": "How body is written. Default markdown."
                        },
                        "excerpt": {
                          "type": "string",
                          "description": "Short summary (WordPress, Ghost)."
                        },
                        "featured_image": {
                          "type": "string",
                          "description": "Public https URL of the featured image (WordPress, Ghost, Blogger)."
                        },
                        "tags": {
                          "type": "array",
                          "items": {
                            "type": "string"
                          },
                          "description": "Tags without the #. Caps per network: postcrow_platform_constraints."
                        },
                        "status": {
                          "type": "string",
                          "enum": [
                            "publish",
                            "draft",
                            "scheduled"
                          ],
                          "description": "What the blog does with it: publish (default), keep as a draft, or publish at publish_at."
                        },
                        "publish_at": {
                          "type": "string",
                          "format": "date-time",
                          "description": "With status scheduled: when the blog publishes it."
                        },
                        "description": {
                          "type": "string",
                          "description": "Description of a video, track, photo or deviation."
                        },
                        "privacy": {
                          "type": "string",
                          "enum": [
                            "public",
                            "unlisted",
                            "private"
                          ],
                          "description": "Media visibility (Vimeo all three; SoundCloud and Flickr public or private)."
                        }
                      },
                      "additionalProperties": false
                    }
                  }
                },
                "required": [
                  "platforms",
                  "title",
                  "body"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The tool result as JSON.",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "400": {
            "description": "Invalid arguments."
          },
          "401": {
            "description": "Missing or invalid API key."
          },
          "402": {
            "description": "The HTTP API is part of the paid plans (Pro, Agency, Platform); the body carries upgrade_url."
          },
          "409": {
            "description": "A request with the same Idempotency-Key is still running, or a conflict reported by the tool."
          },
          "422": {
            "description": "Idempotency-Key reused with another tool or body."
          },
          "429": {
            "description": "Rate limited."
          }
        }
      }
    },
    "/api/v1/tools/postcrow_publish_media": {
      "post": {
        "operationId": "postcrow_publish_media",
        "summary": "Publish a video, track or image",
        "description": "Upload one file to media networks (Vimeo and SoundCloud: a video, MP4 for SoundCloud; Flickr: a photo or a video; DeviantArt: an image) with a title, description, tags and privacy. Postcrow sends it at scheduled_at, in the next queue slot, or keeps it as a Postcrow draft when neither is given. Fi...",
        "x-openai-isConsequential": true,
        "parameters": [
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional, 1 to 255 visible ASCII characters (a UUID). A retry with the same key within 24 hours returns the first answer (header Idempotent-Replayed: true) instead of running again.",
            "schema": {
              "type": "string",
              "maxLength": 255
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "project_id": {
                    "type": "string",
                    "description": "Project (brand) UUID from postcrow_list_projects. If omitted, the user's first project is used."
                  },
                  "platforms": {
                    "type": "array",
                    "minItems": 1,
                    "items": {
                      "type": "string",
                      "enum": [
                        "vimeo",
                        "soundcloud",
                        "flickr",
                        "deviantart"
                      ]
                    }
                  },
                  "media_url": {
                    "type": "string",
                    "description": "Public https URL of the file."
                  },
                  "title": {
                    "type": "string"
                  },
                  "description": {
                    "type": "string"
                  },
                  "tags": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    },
                    "description": "Tags without the #. Caps per network: postcrow_platform_constraints."
                  },
                  "privacy": {
                    "type": "string",
                    "enum": [
                      "public",
                      "unlisted",
                      "private"
                    ],
                    "description": "Default public. Unlisted exists on Vimeo only (private elsewhere); DeviantArt deviations are public."
                  },
                  "scheduled_at": {
                    "type": "string",
                    "format": "date-time",
                    "description": "When Postcrow sends it, ISO 8601 with offset. Omit for a Postcrow draft."
                  },
                  "queue": {
                    "type": "boolean",
                    "description": "Put it in the brand's next free posting slot instead of scheduled_at."
                  },
                  "per_network": {
                    "type": "object",
                    "description": "Per-network versions, keyed by network id: a short text for X and a full article for WordPress in the same post. Each network only accepts the fields it reads (postcrow_platform_constraints lists them); others are refused with the reason.",
                    "additionalProperties": {
                      "type": "object",
                      "properties": {
                        "content": {
                          "type": "string",
                          "description": "This network's own text, instead of the shared content."
                        },
                        "media_urls": {
                          "type": "array",
                          "items": {
                            "type": "string"
                          },
                          "description": "This network's own media, instead of the shared media_urls."
                        },
                        "title": {
                          "type": "string",
                          "description": "Article, video, track, photo or deviation title."
                        },
                        "body": {
                          "type": "string",
                          "description": "Article body (blogs)."
                        },
                        "body_format": {
                          "type": "string",
                          "enum": [
                            "markdown",
                            "html",
                            "text"
                          ],
                          "description": "How body is written. Default markdown."
                        },
                        "excerpt": {
                          "type": "string",
                          "description": "Short summary (WordPress, Ghost)."
                        },
                        "featured_image": {
                          "type": "string",
                          "description": "Public https URL of the featured image (WordPress, Ghost, Blogger)."
                        },
                        "tags": {
                          "type": "array",
                          "items": {
                            "type": "string"
                          },
                          "description": "Tags without the #. Caps per network: postcrow_platform_constraints."
                        },
                        "status": {
                          "type": "string",
                          "enum": [
                            "publish",
                            "draft",
                            "scheduled"
                          ],
                          "description": "What the blog does with it: publish (default), keep as a draft, or publish at publish_at."
                        },
                        "publish_at": {
                          "type": "string",
                          "format": "date-time",
                          "description": "With status scheduled: when the blog publishes it."
                        },
                        "description": {
                          "type": "string",
                          "description": "Description of a video, track, photo or deviation."
                        },
                        "privacy": {
                          "type": "string",
                          "enum": [
                            "public",
                            "unlisted",
                            "private"
                          ],
                          "description": "Media visibility (Vimeo all three; SoundCloud and Flickr public or private)."
                        }
                      },
                      "additionalProperties": false
                    }
                  }
                },
                "required": [
                  "platforms",
                  "media_url",
                  "title"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The tool result as JSON.",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "400": {
            "description": "Invalid arguments."
          },
          "401": {
            "description": "Missing or invalid API key."
          },
          "402": {
            "description": "The HTTP API is part of the paid plans (Pro, Agency, Platform); the body carries upgrade_url."
          },
          "409": {
            "description": "A request with the same Idempotency-Key is still running, or a conflict reported by the tool."
          },
          "422": {
            "description": "Idempotency-Key reused with another tool or body."
          },
          "429": {
            "description": "Rate limited."
          }
        }
      }
    },
    "/api/v1/tools/postcrow_list_projects": {
      "post": {
        "operationId": "postcrow_list_projects",
        "summary": "List brands",
        "description": "List the user's projects. A project is one brand: its own connected accounts, posts, brand voice, timezone and posting slots. Agencies and portfolio operators use one project per brand or client.",
        "x-openai-isConsequential": false,
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {},
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The tool result as JSON.",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "400": {
            "description": "Invalid arguments."
          },
          "401": {
            "description": "Missing or invalid API key."
          },
          "402": {
            "description": "The HTTP API is part of the paid plans (Pro, Agency, Platform); the body carries upgrade_url."
          },
          "429": {
            "description": "Rate limited."
          }
        }
      }
    },
    "/api/v1/tools/postcrow_list_accounts": {
      "post": {
        "operationId": "postcrow_list_accounts",
        "summary": "List connected accounts",
        "description": "List the social accounts connected to a project: network, account name, active status and token health. A post can only target networks listed here. Connecting a new account happens in the browser, at https://postcrow.app/app/accounts.",
        "x-openai-isConsequential": false,
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "project_id": {
                    "type": "string",
                    "description": "Project (brand) UUID from postcrow_list_projects. If omitted, the user's first project is used."
                  }
                },
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The tool result as JSON.",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "400": {
            "description": "Invalid arguments."
          },
          "401": {
            "description": "Missing or invalid API key."
          },
          "402": {
            "description": "The HTTP API is part of the paid plans (Pro, Agency, Platform); the body carries upgrade_url."
          },
          "429": {
            "description": "Rate limited."
          }
        }
      }
    },
    "/api/v1/tools/postcrow_list_posts": {
      "post": {
        "operationId": "postcrow_list_posts",
        "summary": "List posts",
        "description": "List posts in a project, optionally filtered by status (draft, scheduled, publishing, published, failed). Returns id, content, networks, scheduled_at, published_at, per-network results and links.",
        "x-openai-isConsequential": false,
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "project_id": {
                    "type": "string",
                    "description": "Project (brand) UUID from postcrow_list_projects. If omitted, the user's first project is used."
                  },
                  "status": {
                    "type": "string",
                    "enum": [
                      "draft",
                      "scheduled",
                      "publishing",
                      "published",
                      "failed"
                    ]
                  },
                  "limit": {
                    "type": "number",
                    "minimum": 1,
                    "maximum": 100,
                    "default": 20
                  }
                },
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The tool result as JSON.",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "400": {
            "description": "Invalid arguments."
          },
          "401": {
            "description": "Missing or invalid API key."
          },
          "402": {
            "description": "The HTTP API is part of the paid plans (Pro, Agency, Platform); the body carries upgrade_url."
          },
          "429": {
            "description": "Rate limited."
          }
        }
      }
    },
    "/api/v1/tools/postcrow_get_post": {
      "post": {
        "operationId": "postcrow_get_post",
        "summary": "Get a post",
        "description": "One post by id: status (draft, scheduled, publishing, published, failed), content, networks, scheduled_at, published_at, and per network whether it went out, its link and the error if it failed. Use it to follow a post after scheduling or publishing it.",
        "x-openai-isConsequential": false,
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "id": {
                    "type": "string",
                    "description": "Post id."
                  }
                },
                "required": [
                  "id"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The tool result as JSON.",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "400": {
            "description": "Invalid arguments."
          },
          "401": {
            "description": "Missing or invalid API key."
          },
          "402": {
            "description": "The HTTP API is part of the paid plans (Pro, Agency, Platform); the body carries upgrade_url."
          },
          "429": {
            "description": "Rate limited."
          }
        }
      }
    },
    "/api/v1/tools/postcrow_validate_post": {
      "post": {
        "operationId": "postcrow_validate_post",
        "summary": "Validate a post",
        "description": "Check a post before saving it, without saving or counting anything: every problem that would stop it from being scheduled (text too long, missing video or image, a field a network requires, a network not connected on the brand, a time in the past, no posting slots for queue), all at once, per net...",
        "x-openai-isConsequential": false,
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "project_id": {
                    "type": "string",
                    "description": "Project (brand) UUID from postcrow_list_projects. If omitted, the user's first project is used."
                  },
                  "content": {
                    "type": "string"
                  },
                  "platforms": {
                    "type": "array",
                    "items": {
                      "type": "string",
                      "enum": [
                        "facebook",
                        "instagram",
                        "linkedin",
                        "twitter",
                        "telegram",
                        "dailymotion",
                        "mastodon",
                        "discord",
                        "bluesky",
                        "youtube",
                        "tiktok",
                        "threads",
                        "pinterest",
                        "reddit",
                        "devto",
                        "hashnode",
                        "snapchat",
                        "peertube",
                        "kick",
                        "twitch",
                        "tumblr",
                        "wordpress",
                        "wordpress_self",
                        "ghost",
                        "blogger",
                        "hatena",
                        "vimeo",
                        "soundcloud",
                        "deviantart",
                        "flickr",
                        "meetup",
                        "nextdoor",
                        "band",
                        "weibo",
                        "letterboxd"
                      ]
                    },
                    "description": "Target networks. Each must be connected on the project: call postcrow_list_accounts first. Call postcrow_network_rules for each network's text limit and media rules."
                  },
                  "media_urls": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    },
                    "description": "Public https URLs of images or videos to attach. Video networks (YouTube, Dailymotion, PeerTube, Vimeo, SoundCloud as MP4) need exactly one video. Formats and sizes: postcrow_platform_constraints."
                  },
                  "per_network": {
                    "type": "object",
                    "description": "Per-network versions, keyed by network id: a short text for X and a full article for WordPress in the same post. Each network only accepts the fields it reads (postcrow_platform_constraints lists them); others are refused with the reason.",
                    "additionalProperties": {
                      "type": "object",
                      "properties": {
                        "content": {
                          "type": "string",
                          "description": "This network's own text, instead of the shared content."
                        },
                        "media_urls": {
                          "type": "array",
                          "items": {
                            "type": "string"
                          },
                          "description": "This network's own media, instead of the shared media_urls."
                        },
                        "title": {
                          "type": "string",
                          "description": "Article, video, track, photo or deviation title."
                        },
                        "body": {
                          "type": "string",
                          "description": "Article body (blogs)."
                        },
                        "body_format": {
                          "type": "string",
                          "enum": [
                            "markdown",
                            "html",
                            "text"
                          ],
                          "description": "How body is written. Default markdown."
                        },
                        "excerpt": {
                          "type": "string",
                          "description": "Short summary (WordPress, Ghost)."
                        },
                        "featured_image": {
                          "type": "string",
                          "description": "Public https URL of the featured image (WordPress, Ghost, Blogger)."
                        },
                        "tags": {
                          "type": "array",
                          "items": {
                            "type": "string"
                          },
                          "description": "Tags without the #. Caps per network: postcrow_platform_constraints."
                        },
                        "status": {
                          "type": "string",
                          "enum": [
                            "publish",
                            "draft",
                            "scheduled"
                          ],
                          "description": "What the blog does with it: publish (default), keep as a draft, or publish at publish_at."
                        },
                        "publish_at": {
                          "type": "string",
                          "format": "date-time",
                          "description": "With status scheduled: when the blog publishes it."
                        },
                        "description": {
                          "type": "string",
                          "description": "Description of a video, track, photo or deviation."
                        },
                        "privacy": {
                          "type": "string",
                          "enum": [
                            "public",
                            "unlisted",
                            "private"
                          ],
                          "description": "Media visibility (Vimeo all three; SoundCloud and Flickr public or private)."
                        }
                      },
                      "additionalProperties": false
                    }
                  },
                  "scheduled_at": {
                    "type": "string",
                    "format": "date-time",
                    "description": "Optional: also check that this time is in the future."
                  },
                  "queue": {
                    "type": "boolean",
                    "description": "Optional: also check that the brand has posting slots."
                  }
                },
                "required": [
                  "content",
                  "platforms"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The tool result as JSON.",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "400": {
            "description": "Invalid arguments."
          },
          "401": {
            "description": "Missing or invalid API key."
          },
          "402": {
            "description": "The HTTP API is part of the paid plans (Pro, Agency, Platform); the body carries upgrade_url."
          },
          "429": {
            "description": "Rate limited."
          }
        }
      }
    },
    "/api/v1/tools/postcrow_create_draft": {
      "post": {
        "operationId": "postcrow_create_draft",
        "summary": "Create a draft",
        "description": "Save a post as a draft, without scheduling it. The user can review it in the app; schedule it later with postcrow_update_post (scheduled_at) or publish it with postcrow_publish_now.",
        "x-openai-isConsequential": true,
        "parameters": [
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional, 1 to 255 visible ASCII characters (a UUID). A retry with the same key within 24 hours returns the first answer (header Idempotent-Replayed: true) instead of running again.",
            "schema": {
              "type": "string",
              "maxLength": 255
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "project_id": {
                    "type": "string",
                    "description": "Project (brand) UUID from postcrow_list_projects. If omitted, the user's first project is used."
                  },
                  "content": {
                    "type": "string",
                    "description": "Post text. Plain text; write hashtags and line breaks yourself."
                  },
                  "platforms": {
                    "type": "array",
                    "items": {
                      "type": "string",
                      "enum": [
                        "facebook",
                        "instagram",
                        "linkedin",
                        "twitter",
                        "telegram",
                        "dailymotion",
                        "mastodon",
                        "discord",
                        "bluesky",
                        "youtube",
                        "tiktok",
                        "threads",
                        "pinterest",
                        "reddit",
                        "devto",
                        "hashnode",
                        "snapchat",
                        "peertube",
                        "kick",
                        "twitch",
                        "tumblr",
                        "wordpress",
                        "wordpress_self",
                        "ghost",
                        "blogger",
                        "hatena",
                        "vimeo",
                        "soundcloud",
                        "deviantart",
                        "flickr",
                        "meetup",
                        "nextdoor",
                        "band",
                        "weibo",
                        "letterboxd"
                      ]
                    },
                    "description": "Target networks. Each must be connected on the project: call postcrow_list_accounts first. Call postcrow_network_rules for each network's text limit and media rules."
                  },
                  "media_urls": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    },
                    "description": "Public https URLs of images or videos to attach. Video networks (YouTube, Dailymotion, PeerTube, Vimeo, SoundCloud as MP4) need exactly one video. Formats and sizes: postcrow_platform_constraints."
                  },
                  "per_network": {
                    "type": "object",
                    "description": "Per-network versions, keyed by network id: a short text for X and a full article for WordPress in the same post. Each network only accepts the fields it reads (postcrow_platform_constraints lists them); others are refused with the reason.",
                    "additionalProperties": {
                      "type": "object",
                      "properties": {
                        "content": {
                          "type": "string",
                          "description": "This network's own text, instead of the shared content."
                        },
                        "media_urls": {
                          "type": "array",
                          "items": {
                            "type": "string"
                          },
                          "description": "This network's own media, instead of the shared media_urls."
                        },
                        "title": {
                          "type": "string",
                          "description": "Article, video, track, photo or deviation title."
                        },
                        "body": {
                          "type": "string",
                          "description": "Article body (blogs)."
                        },
                        "body_format": {
                          "type": "string",
                          "enum": [
                            "markdown",
                            "html",
                            "text"
                          ],
                          "description": "How body is written. Default markdown."
                        },
                        "excerpt": {
                          "type": "string",
                          "description": "Short summary (WordPress, Ghost)."
                        },
                        "featured_image": {
                          "type": "string",
                          "description": "Public https URL of the featured image (WordPress, Ghost, Blogger)."
                        },
                        "tags": {
                          "type": "array",
                          "items": {
                            "type": "string"
                          },
                          "description": "Tags without the #. Caps per network: postcrow_platform_constraints."
                        },
                        "status": {
                          "type": "string",
                          "enum": [
                            "publish",
                            "draft",
                            "scheduled"
                          ],
                          "description": "What the blog does with it: publish (default), keep as a draft, or publish at publish_at."
                        },
                        "publish_at": {
                          "type": "string",
                          "format": "date-time",
                          "description": "With status scheduled: when the blog publishes it."
                        },
                        "description": {
                          "type": "string",
                          "description": "Description of a video, track, photo or deviation."
                        },
                        "privacy": {
                          "type": "string",
                          "enum": [
                            "public",
                            "unlisted",
                            "private"
                          ],
                          "description": "Media visibility (Vimeo all three; SoundCloud and Flickr public or private)."
                        }
                      },
                      "additionalProperties": false
                    }
                  }
                },
                "required": [
                  "content",
                  "platforms"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The tool result as JSON.",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "400": {
            "description": "Invalid arguments."
          },
          "401": {
            "description": "Missing or invalid API key."
          },
          "402": {
            "description": "The HTTP API is part of the paid plans (Pro, Agency, Platform); the body carries upgrade_url."
          },
          "409": {
            "description": "A request with the same Idempotency-Key is still running, or a conflict reported by the tool."
          },
          "422": {
            "description": "Idempotency-Key reused with another tool or body."
          },
          "429": {
            "description": "Rate limited."
          }
        }
      }
    },
    "/api/v1/tools/postcrow_schedule_post": {
      "post": {
        "operationId": "postcrow_schedule_post",
        "summary": "Schedule a post",
        "description": "Schedule a post for an exact future time. Postcrow publishes it on every selected network at that time. A post that includes Reddit is saved as a draft instead, for a person to confirm in the app. To let the brand's posting schedule pick the time, use postcrow_queue_post instead.",
        "x-openai-isConsequential": true,
        "parameters": [
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional, 1 to 255 visible ASCII characters (a UUID). A retry with the same key within 24 hours returns the first answer (header Idempotent-Replayed: true) instead of running again.",
            "schema": {
              "type": "string",
              "maxLength": 255
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "project_id": {
                    "type": "string",
                    "description": "Project (brand) UUID from postcrow_list_projects. If omitted, the user's first project is used."
                  },
                  "content": {
                    "type": "string"
                  },
                  "platforms": {
                    "type": "array",
                    "items": {
                      "type": "string",
                      "enum": [
                        "facebook",
                        "instagram",
                        "linkedin",
                        "twitter",
                        "telegram",
                        "dailymotion",
                        "mastodon",
                        "discord",
                        "bluesky",
                        "youtube",
                        "tiktok",
                        "threads",
                        "pinterest",
                        "reddit",
                        "devto",
                        "hashnode",
                        "snapchat",
                        "peertube",
                        "kick",
                        "twitch",
                        "tumblr",
                        "wordpress",
                        "wordpress_self",
                        "ghost",
                        "blogger",
                        "hatena",
                        "vimeo",
                        "soundcloud",
                        "deviantart",
                        "flickr",
                        "meetup",
                        "nextdoor",
                        "band",
                        "weibo",
                        "letterboxd"
                      ]
                    },
                    "description": "Target networks. Each must be connected on the project: call postcrow_list_accounts first. Call postcrow_network_rules for each network's text limit and media rules."
                  },
                  "scheduled_at": {
                    "type": "string",
                    "format": "date-time",
                    "description": "ISO 8601 with offset, e.g. 2026-11-20T09:00:00+01:00. Must be in the future."
                  },
                  "media_urls": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    },
                    "description": "Public https URLs of images or videos to attach. Video networks (YouTube, Dailymotion, PeerTube, Vimeo, SoundCloud as MP4) need exactly one video. Formats and sizes: postcrow_platform_constraints."
                  },
                  "per_network": {
                    "type": "object",
                    "description": "Per-network versions, keyed by network id: a short text for X and a full article for WordPress in the same post. Each network only accepts the fields it reads (postcrow_platform_constraints lists them); others are refused with the reason.",
                    "additionalProperties": {
                      "type": "object",
                      "properties": {
                        "content": {
                          "type": "string",
                          "description": "This network's own text, instead of the shared content."
                        },
                        "media_urls": {
                          "type": "array",
                          "items": {
                            "type": "string"
                          },
                          "description": "This network's own media, instead of the shared media_urls."
                        },
                        "title": {
                          "type": "string",
                          "description": "Article, video, track, photo or deviation title."
                        },
                        "body": {
                          "type": "string",
                          "description": "Article body (blogs)."
                        },
                        "body_format": {
                          "type": "string",
                          "enum": [
                            "markdown",
                            "html",
                            "text"
                          ],
                          "description": "How body is written. Default markdown."
                        },
                        "excerpt": {
                          "type": "string",
                          "description": "Short summary (WordPress, Ghost)."
                        },
                        "featured_image": {
                          "type": "string",
                          "description": "Public https URL of the featured image (WordPress, Ghost, Blogger)."
                        },
                        "tags": {
                          "type": "array",
                          "items": {
                            "type": "string"
                          },
                          "description": "Tags without the #. Caps per network: postcrow_platform_constraints."
                        },
                        "status": {
                          "type": "string",
                          "enum": [
                            "publish",
                            "draft",
                            "scheduled"
                          ],
                          "description": "What the blog does with it: publish (default), keep as a draft, or publish at publish_at."
                        },
                        "publish_at": {
                          "type": "string",
                          "format": "date-time",
                          "description": "With status scheduled: when the blog publishes it."
                        },
                        "description": {
                          "type": "string",
                          "description": "Description of a video, track, photo or deviation."
                        },
                        "privacy": {
                          "type": "string",
                          "enum": [
                            "public",
                            "unlisted",
                            "private"
                          ],
                          "description": "Media visibility (Vimeo all three; SoundCloud and Flickr public or private)."
                        }
                      },
                      "additionalProperties": false
                    }
                  }
                },
                "required": [
                  "content",
                  "platforms",
                  "scheduled_at"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The tool result as JSON.",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "400": {
            "description": "Invalid arguments."
          },
          "401": {
            "description": "Missing or invalid API key."
          },
          "402": {
            "description": "The HTTP API is part of the paid plans (Pro, Agency, Platform); the body carries upgrade_url."
          },
          "409": {
            "description": "A request with the same Idempotency-Key is still running, or a conflict reported by the tool."
          },
          "422": {
            "description": "Idempotency-Key reused with another tool or body."
          },
          "429": {
            "description": "Rate limited."
          }
        }
      }
    },
    "/api/v1/tools/postcrow_queue_post": {
      "post": {
        "operationId": "postcrow_queue_post",
        "summary": "Queue a post",
        "description": "Add a post to a brand's queue: the server picks the next free slot from the project's posting schedule, so several posts queued in a row land on consecutive slots. Fails with code no_slots when the project has no schedule (set one with postcrow_project_settings) and queue_full when the next 120 d...",
        "x-openai-isConsequential": true,
        "parameters": [
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional, 1 to 255 visible ASCII characters (a UUID). A retry with the same key within 24 hours returns the first answer (header Idempotent-Replayed: true) instead of running again.",
            "schema": {
              "type": "string",
              "maxLength": 255
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "project_id": {
                    "type": "string",
                    "description": "Project (brand) UUID from postcrow_list_projects. If omitted, the user's first project is used."
                  },
                  "content": {
                    "type": "string"
                  },
                  "platforms": {
                    "type": "array",
                    "items": {
                      "type": "string",
                      "enum": [
                        "facebook",
                        "instagram",
                        "linkedin",
                        "twitter",
                        "telegram",
                        "dailymotion",
                        "mastodon",
                        "discord",
                        "bluesky",
                        "youtube",
                        "tiktok",
                        "threads",
                        "pinterest",
                        "reddit",
                        "devto",
                        "hashnode",
                        "snapchat",
                        "peertube",
                        "kick",
                        "twitch",
                        "tumblr",
                        "wordpress",
                        "wordpress_self",
                        "ghost",
                        "blogger",
                        "hatena",
                        "vimeo",
                        "soundcloud",
                        "deviantart",
                        "flickr",
                        "meetup",
                        "nextdoor",
                        "band",
                        "weibo",
                        "letterboxd"
                      ]
                    },
                    "description": "Target networks. Each must be connected on the project: call postcrow_list_accounts first. Call postcrow_network_rules for each network's text limit and media rules."
                  },
                  "media_urls": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    },
                    "description": "Public https URLs of images or videos to attach. Video networks (YouTube, Dailymotion, PeerTube, Vimeo, SoundCloud as MP4) need exactly one video. Formats and sizes: postcrow_platform_constraints."
                  },
                  "per_network": {
                    "type": "object",
                    "description": "Per-network versions, keyed by network id: a short text for X and a full article for WordPress in the same post. Each network only accepts the fields it reads (postcrow_platform_constraints lists them); others are refused with the reason.",
                    "additionalProperties": {
                      "type": "object",
                      "properties": {
                        "content": {
                          "type": "string",
                          "description": "This network's own text, instead of the shared content."
                        },
                        "media_urls": {
                          "type": "array",
                          "items": {
                            "type": "string"
                          },
                          "description": "This network's own media, instead of the shared media_urls."
                        },
                        "title": {
                          "type": "string",
                          "description": "Article, video, track, photo or deviation title."
                        },
                        "body": {
                          "type": "string",
                          "description": "Article body (blogs)."
                        },
                        "body_format": {
                          "type": "string",
                          "enum": [
                            "markdown",
                            "html",
                            "text"
                          ],
                          "description": "How body is written. Default markdown."
                        },
                        "excerpt": {
                          "type": "string",
                          "description": "Short summary (WordPress, Ghost)."
                        },
                        "featured_image": {
                          "type": "string",
                          "description": "Public https URL of the featured image (WordPress, Ghost, Blogger)."
                        },
                        "tags": {
                          "type": "array",
                          "items": {
                            "type": "string"
                          },
                          "description": "Tags without the #. Caps per network: postcrow_platform_constraints."
                        },
                        "status": {
                          "type": "string",
                          "enum": [
                            "publish",
                            "draft",
                            "scheduled"
                          ],
                          "description": "What the blog does with it: publish (default), keep as a draft, or publish at publish_at."
                        },
                        "publish_at": {
                          "type": "string",
                          "format": "date-time",
                          "description": "With status scheduled: when the blog publishes it."
                        },
                        "description": {
                          "type": "string",
                          "description": "Description of a video, track, photo or deviation."
                        },
                        "privacy": {
                          "type": "string",
                          "enum": [
                            "public",
                            "unlisted",
                            "private"
                          ],
                          "description": "Media visibility (Vimeo all three; SoundCloud and Flickr public or private)."
                        }
                      },
                      "additionalProperties": false
                    }
                  }
                },
                "required": [
                  "content",
                  "platforms"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The tool result as JSON.",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "400": {
            "description": "Invalid arguments."
          },
          "401": {
            "description": "Missing or invalid API key."
          },
          "402": {
            "description": "The HTTP API is part of the paid plans (Pro, Agency, Platform); the body carries upgrade_url."
          },
          "409": {
            "description": "A request with the same Idempotency-Key is still running, or a conflict reported by the tool."
          },
          "422": {
            "description": "Idempotency-Key reused with another tool or body."
          },
          "429": {
            "description": "Rate limited."
          }
        }
      }
    },
    "/api/v1/tools/postcrow_update_post": {
      "post": {
        "operationId": "postcrow_update_post",
        "summary": "Update a post",
        "description": "Change a draft or scheduled post: content, networks, media or time. Pass scheduled_at to turn a draft into a scheduled post, or null to move a scheduled post back to drafts.",
        "x-openai-isConsequential": true,
        "parameters": [
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional, 1 to 255 visible ASCII characters (a UUID). A retry with the same key within 24 hours returns the first answer (header Idempotent-Replayed: true) instead of running again.",
            "schema": {
              "type": "string",
              "maxLength": 255
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "id": {
                    "type": "string",
                    "description": "Post id."
                  },
                  "content": {
                    "type": "string"
                  },
                  "platforms": {
                    "type": "array",
                    "items": {
                      "type": "string",
                      "enum": [
                        "facebook",
                        "instagram",
                        "linkedin",
                        "twitter",
                        "telegram",
                        "dailymotion",
                        "mastodon",
                        "discord",
                        "bluesky",
                        "youtube",
                        "tiktok",
                        "threads",
                        "pinterest",
                        "reddit",
                        "devto",
                        "hashnode",
                        "snapchat",
                        "peertube",
                        "kick",
                        "twitch",
                        "tumblr",
                        "wordpress",
                        "wordpress_self",
                        "ghost",
                        "blogger",
                        "hatena",
                        "vimeo",
                        "soundcloud",
                        "deviantart",
                        "flickr",
                        "meetup",
                        "nextdoor",
                        "band",
                        "weibo",
                        "letterboxd"
                      ]
                    },
                    "description": "Target networks. Each must be connected on the project: call postcrow_list_accounts first. Call postcrow_network_rules for each network's text limit and media rules."
                  },
                  "scheduled_at": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "description": "ISO 8601, or null for draft."
                  },
                  "media_urls": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    },
                    "description": "Public https URLs of images or videos to attach. Video networks (YouTube, Dailymotion, PeerTube, Vimeo, SoundCloud as MP4) need exactly one video. Formats and sizes: postcrow_platform_constraints."
                  },
                  "per_network": {
                    "type": "object",
                    "description": "Per-network versions, keyed by network id: a short text for X and a full article for WordPress in the same post. Each network only accepts the fields it reads (postcrow_platform_constraints lists them); others are refused with the reason. Replaces the post's per-network versions as a whole.",
                    "additionalProperties": {
                      "type": "object",
                      "properties": {
                        "content": {
                          "type": "string",
                          "description": "This network's own text, instead of the shared content."
                        },
                        "media_urls": {
                          "type": "array",
                          "items": {
                            "type": "string"
                          },
                          "description": "This network's own media, instead of the shared media_urls."
                        },
                        "title": {
                          "type": "string",
                          "description": "Article, video, track, photo or deviation title."
                        },
                        "body": {
                          "type": "string",
                          "description": "Article body (blogs)."
                        },
                        "body_format": {
                          "type": "string",
                          "enum": [
                            "markdown",
                            "html",
                            "text"
                          ],
                          "description": "How body is written. Default markdown."
                        },
                        "excerpt": {
                          "type": "string",
                          "description": "Short summary (WordPress, Ghost)."
                        },
                        "featured_image": {
                          "type": "string",
                          "description": "Public https URL of the featured image (WordPress, Ghost, Blogger)."
                        },
                        "tags": {
                          "type": "array",
                          "items": {
                            "type": "string"
                          },
                          "description": "Tags without the #. Caps per network: postcrow_platform_constraints."
                        },
                        "status": {
                          "type": "string",
                          "enum": [
                            "publish",
                            "draft",
                            "scheduled"
                          ],
                          "description": "What the blog does with it: publish (default), keep as a draft, or publish at publish_at."
                        },
                        "publish_at": {
                          "type": "string",
                          "format": "date-time",
                          "description": "With status scheduled: when the blog publishes it."
                        },
                        "description": {
                          "type": "string",
                          "description": "Description of a video, track, photo or deviation."
                        },
                        "privacy": {
                          "type": "string",
                          "enum": [
                            "public",
                            "unlisted",
                            "private"
                          ],
                          "description": "Media visibility (Vimeo all three; SoundCloud and Flickr public or private)."
                        }
                      },
                      "additionalProperties": false
                    }
                  }
                },
                "required": [
                  "id"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The tool result as JSON.",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "400": {
            "description": "Invalid arguments."
          },
          "401": {
            "description": "Missing or invalid API key."
          },
          "402": {
            "description": "The HTTP API is part of the paid plans (Pro, Agency, Platform); the body carries upgrade_url."
          },
          "409": {
            "description": "A request with the same Idempotency-Key is still running, or a conflict reported by the tool."
          },
          "422": {
            "description": "Idempotency-Key reused with another tool or body."
          },
          "429": {
            "description": "Rate limited."
          }
        }
      }
    },
    "/api/v1/tools/postcrow_publish_now": {
      "post": {
        "operationId": "postcrow_publish_now",
        "summary": "Publish now",
        "description": "Publish a draft or scheduled post right now, on every selected network. This posts publicly on the user's real accounts: confirm with the user first. Returns per-network results and links. Refused for a post that includes Reddit: Reddit posts are confirmed and published by a person in the Postcro...",
        "x-openai-isConsequential": true,
        "parameters": [
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional, 1 to 255 visible ASCII characters (a UUID). A retry with the same key within 24 hours returns the first answer (header Idempotent-Replayed: true) instead of running again.",
            "schema": {
              "type": "string",
              "maxLength": 255
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "id": {
                    "type": "string",
                    "description": "Post id."
                  }
                },
                "required": [
                  "id"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The tool result as JSON.",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "400": {
            "description": "Invalid arguments."
          },
          "401": {
            "description": "Missing or invalid API key."
          },
          "402": {
            "description": "The HTTP API is part of the paid plans (Pro, Agency, Platform); the body carries upgrade_url."
          },
          "409": {
            "description": "A request with the same Idempotency-Key is still running, or a conflict reported by the tool."
          },
          "422": {
            "description": "Idempotency-Key reused with another tool or body."
          },
          "429": {
            "description": "Rate limited."
          }
        }
      }
    },
    "/api/v1/tools/postcrow_delete_post": {
      "post": {
        "operationId": "postcrow_delete_post",
        "summary": "Delete a post",
        "description": "Delete a post from Postcrow. For a published post only the Postcrow record goes; the copy on the network stays up.",
        "x-openai-isConsequential": true,
        "parameters": [
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional, 1 to 255 visible ASCII characters (a UUID). A retry with the same key within 24 hours returns the first answer (header Idempotent-Replayed: true) instead of running again.",
            "schema": {
              "type": "string",
              "maxLength": 255
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "id": {
                    "type": "string",
                    "description": "Post id."
                  }
                },
                "required": [
                  "id"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The tool result as JSON.",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "400": {
            "description": "Invalid arguments."
          },
          "401": {
            "description": "Missing or invalid API key."
          },
          "402": {
            "description": "The HTTP API is part of the paid plans (Pro, Agency, Platform); the body carries upgrade_url."
          },
          "409": {
            "description": "A request with the same Idempotency-Key is still running, or a conflict reported by the tool."
          },
          "422": {
            "description": "Idempotency-Key reused with another tool or body."
          },
          "429": {
            "description": "Rate limited."
          }
        }
      }
    },
    "/api/v1/tools/postcrow_reorder_queue": {
      "post": {
        "operationId": "postcrow_reorder_queue",
        "summary": "Reorder the queue",
        "description": "Move a scheduled post one place up or down in its brand's queue. The two posts swap their times, so the slots stay the same and only the order changes.",
        "x-openai-isConsequential": true,
        "parameters": [
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional, 1 to 255 visible ASCII characters (a UUID). A retry with the same key within 24 hours returns the first answer (header Idempotent-Replayed: true) instead of running again.",
            "schema": {
              "type": "string",
              "maxLength": 255
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "id": {
                    "type": "string",
                    "description": "Post id, from postcrow_list_posts with status=scheduled."
                  },
                  "direction": {
                    "type": "string",
                    "enum": [
                      "up",
                      "down"
                    ],
                    "description": "up = sooner, down = later."
                  }
                },
                "required": [
                  "id",
                  "direction"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The tool result as JSON.",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "400": {
            "description": "Invalid arguments."
          },
          "401": {
            "description": "Missing or invalid API key."
          },
          "402": {
            "description": "The HTTP API is part of the paid plans (Pro, Agency, Platform); the body carries upgrade_url."
          },
          "409": {
            "description": "A request with the same Idempotency-Key is still running, or a conflict reported by the tool."
          },
          "422": {
            "description": "Idempotency-Key reused with another tool or body."
          },
          "429": {
            "description": "Rate limited."
          }
        }
      }
    },
    "/api/v1/tools/postcrow_recycle_post": {
      "post": {
        "operationId": "postcrow_recycle_post",
        "summary": "Recycle a post",
        "description": "Copy a published post to a new date (or to drafts with scheduled_at null). Same text, same networks.",
        "x-openai-isConsequential": true,
        "parameters": [
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional, 1 to 255 visible ASCII characters (a UUID). A retry with the same key within 24 hours returns the first answer (header Idempotent-Replayed: true) instead of running again.",
            "schema": {
              "type": "string",
              "maxLength": 255
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "post_id": {
                    "type": "string",
                    "description": "Id of the published post."
                  },
                  "scheduled_at": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "description": "ISO 8601 for the copy, or null for a draft."
                  }
                },
                "required": [
                  "post_id"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The tool result as JSON.",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "400": {
            "description": "Invalid arguments."
          },
          "401": {
            "description": "Missing or invalid API key."
          },
          "402": {
            "description": "The HTTP API is part of the paid plans (Pro, Agency, Platform); the body carries upgrade_url."
          },
          "409": {
            "description": "A request with the same Idempotency-Key is still running, or a conflict reported by the tool."
          },
          "422": {
            "description": "Idempotency-Key reused with another tool or body."
          },
          "429": {
            "description": "Rate limited."
          }
        }
      }
    },
    "/api/v1/tools/postcrow_top_posts": {
      "post": {
        "operationId": "postcrow_top_posts",
        "summary": "Top posts",
        "description": "The best published posts of a project by engagement (likes + 2 x comments + 3 x shares), from the figures Postcrow already collected. Useful to pick what to recycle or to learn what works for a brand.",
        "x-openai-isConsequential": false,
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "project_id": {
                    "type": "string",
                    "description": "Project (brand) UUID from postcrow_list_projects. If omitted, the user's first project is used."
                  },
                  "limit": {
                    "type": "number",
                    "minimum": 1,
                    "maximum": 20,
                    "default": 5
                  }
                },
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The tool result as JSON.",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "400": {
            "description": "Invalid arguments."
          },
          "401": {
            "description": "Missing or invalid API key."
          },
          "402": {
            "description": "The HTTP API is part of the paid plans (Pro, Agency, Platform); the body carries upgrade_url."
          },
          "429": {
            "description": "Rate limited."
          }
        }
      }
    },
    "/api/v1/tools/postcrow_cross_project_overview": {
      "post": {
        "operationId": "postcrow_cross_project_overview",
        "summary": "All brands overview",
        "description": "Everything scheduled across ALL the user's projects in a date window, as one timeline. Defaults to the next 30 days.",
        "x-openai-isConsequential": false,
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "from": {
                    "type": "string",
                    "format": "date-time",
                    "description": "ISO start. Defaults to now."
                  },
                  "to": {
                    "type": "string",
                    "format": "date-time",
                    "description": "ISO end. Defaults to now + 30 days."
                  }
                },
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The tool result as JSON.",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "400": {
            "description": "Invalid arguments."
          },
          "401": {
            "description": "Missing or invalid API key."
          },
          "402": {
            "description": "The HTTP API is part of the paid plans (Pro, Agency, Platform); the body carries upgrade_url."
          },
          "429": {
            "description": "Rate limited."
          }
        }
      }
    },
    "/api/v1/tools/postcrow_bulk_schedule": {
      "post": {
        "operationId": "postcrow_bulk_schedule",
        "summary": "Bulk schedule",
        "description": "Schedule up to 200 posts for one project, spread evenly between from and to. Posts that would land in the past are skipped.",
        "x-openai-isConsequential": true,
        "parameters": [
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional, 1 to 255 visible ASCII characters (a UUID). A retry with the same key within 24 hours returns the first answer (header Idempotent-Replayed: true) instead of running again.",
            "schema": {
              "type": "string",
              "maxLength": 255
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "project_id": {
                    "type": "string",
                    "description": "Project (brand) UUID from postcrow_list_projects. If omitted, the user's first project is used."
                  },
                  "from": {
                    "type": "string",
                    "format": "date-time",
                    "description": "Time of the first post."
                  },
                  "to": {
                    "type": "string",
                    "format": "date-time",
                    "description": "Time of the last post."
                  },
                  "posts": {
                    "type": "array",
                    "minItems": 1,
                    "maxItems": 200,
                    "items": {
                      "type": "object",
                      "properties": {
                        "content": {
                          "type": "string"
                        },
                        "platforms": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "enum": [
                              "facebook",
                              "instagram",
                              "linkedin",
                              "twitter",
                              "telegram",
                              "dailymotion",
                              "mastodon",
                              "discord",
                              "bluesky",
                              "youtube",
                              "tiktok",
                              "threads",
                              "pinterest",
                              "reddit",
                              "devto",
                              "hashnode",
                              "snapchat",
                              "peertube",
                              "kick",
                              "twitch",
                              "tumblr",
                              "wordpress",
                              "wordpress_self",
                              "ghost",
                              "blogger",
                              "hatena",
                              "vimeo",
                              "soundcloud",
                              "deviantart",
                              "flickr",
                              "meetup",
                              "nextdoor",
                              "band",
                              "weibo",
                              "letterboxd"
                            ]
                          },
                          "description": "Target networks. Each must be connected on the project: call postcrow_list_accounts first. Call postcrow_network_rules for each network's text limit and media rules."
                        },
                        "media_urls": {
                          "type": "array",
                          "items": {
                            "type": "string"
                          },
                          "description": "Public https URLs of images or videos to attach. Video networks (YouTube, Dailymotion, PeerTube, Vimeo, SoundCloud as MP4) need exactly one video. Formats and sizes: postcrow_platform_constraints."
                        },
                        "per_network": {
                          "type": "object",
                          "description": "Per-network versions, keyed by network id: a short text for X and a full article for WordPress in the same post. Each network only accepts the fields it reads (postcrow_platform_constraints lists them); others are refused with the reason.",
                          "additionalProperties": {
                            "type": "object",
                            "properties": {
                              "content": {
                                "type": "string",
                                "description": "This network's own text, instead of the shared content."
                              },
                              "media_urls": {
                                "type": "array",
                                "items": {
                                  "type": "string"
                                },
                                "description": "This network's own media, instead of the shared media_urls."
                              },
                              "title": {
                                "type": "string",
                                "description": "Article, video, track, photo or deviation title."
                              },
                              "body": {
                                "type": "string",
                                "description": "Article body (blogs)."
                              },
                              "body_format": {
                                "type": "string",
                                "enum": [
                                  "markdown",
                                  "html",
                                  "text"
                                ],
                                "description": "How body is written. Default markdown."
                              },
                              "excerpt": {
                                "type": "string",
                                "description": "Short summary (WordPress, Ghost)."
                              },
                              "featured_image": {
                                "type": "string",
                                "description": "Public https URL of the featured image (WordPress, Ghost, Blogger)."
                              },
                              "tags": {
                                "type": "array",
                                "items": {
                                  "type": "string"
                                },
                                "description": "Tags without the #. Caps per network: postcrow_platform_constraints."
                              },
                              "status": {
                                "type": "string",
                                "enum": [
                                  "publish",
                                  "draft",
                                  "scheduled"
                                ],
                                "description": "What the blog does with it: publish (default), keep as a draft, or publish at publish_at."
                              },
                              "publish_at": {
                                "type": "string",
                                "format": "date-time",
                                "description": "With status scheduled: when the blog publishes it."
                              },
                              "description": {
                                "type": "string",
                                "description": "Description of a video, track, photo or deviation."
                              },
                              "privacy": {
                                "type": "string",
                                "enum": [
                                  "public",
                                  "unlisted",
                                  "private"
                                ],
                                "description": "Media visibility (Vimeo all three; SoundCloud and Flickr public or private)."
                              }
                            },
                            "additionalProperties": false
                          }
                        }
                      },
                      "required": [
                        "content",
                        "platforms"
                      ],
                      "additionalProperties": false
                    }
                  }
                },
                "required": [
                  "from",
                  "to",
                  "posts"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The tool result as JSON.",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "400": {
            "description": "Invalid arguments."
          },
          "401": {
            "description": "Missing or invalid API key."
          },
          "402": {
            "description": "The HTTP API is part of the paid plans (Pro, Agency, Platform); the body carries upgrade_url."
          },
          "409": {
            "description": "A request with the same Idempotency-Key is still running, or a conflict reported by the tool."
          },
          "422": {
            "description": "Idempotency-Key reused with another tool or body."
          },
          "429": {
            "description": "Rate limited."
          }
        }
      }
    },
    "/api/v1/tools/postcrow_ai_compose": {
      "post": {
        "operationId": "postcrow_ai_compose",
        "summary": "Write drafts with Postcrow AI",
        "description": "Postcrow's own writer: one brief in, one draft per network out, each fitted to that network's tone and limit, in the project's trained brand voice when project_id is given. Returns drafts only; nothing is saved. You can also write the posts yourself and skip this tool.",
        "x-openai-isConsequential": false,
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "brief": {
                    "type": "string",
                    "description": "What to say: a topic, an announcement, a summary of an article."
                  },
                  "platforms": {
                    "type": "array",
                    "items": {
                      "type": "string",
                      "enum": [
                        "facebook",
                        "instagram",
                        "linkedin",
                        "twitter",
                        "telegram",
                        "dailymotion",
                        "mastodon",
                        "discord",
                        "bluesky",
                        "youtube",
                        "tiktok",
                        "threads",
                        "pinterest",
                        "reddit",
                        "devto",
                        "hashnode",
                        "snapchat",
                        "peertube",
                        "kick",
                        "twitch",
                        "tumblr",
                        "wordpress",
                        "wordpress_self",
                        "ghost",
                        "blogger",
                        "hatena",
                        "vimeo",
                        "soundcloud",
                        "deviantart",
                        "flickr",
                        "meetup",
                        "nextdoor",
                        "band",
                        "weibo",
                        "letterboxd"
                      ]
                    },
                    "description": "Target networks. Each must be connected on the project: call postcrow_list_accounts first. Call postcrow_network_rules for each network's text limit and media rules.",
                    "minItems": 1
                  },
                  "project_id": {
                    "type": "string",
                    "description": "Uses this project's trained brand voice."
                  },
                  "tone": {
                    "type": "string",
                    "description": "professional, casual, playful, inspiring or urgent. Default professional."
                  },
                  "language": {
                    "type": "string",
                    "enum": [
                      "EN",
                      "FR"
                    ],
                    "description": "Default EN."
                  },
                  "brand_voice": {
                    "type": "string",
                    "description": "Inline voice description; overrides the project's."
                  }
                },
                "required": [
                  "brief",
                  "platforms"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The tool result as JSON.",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "400": {
            "description": "Invalid arguments."
          },
          "401": {
            "description": "Missing or invalid API key."
          },
          "402": {
            "description": "The HTTP API is part of the paid plans (Pro, Agency, Platform); the body carries upgrade_url."
          },
          "429": {
            "description": "Rate limited."
          }
        }
      }
    },
    "/api/v1/tools/postcrow_smart_recycle": {
      "post": {
        "operationId": "postcrow_smart_recycle",
        "summary": "Rewrite top posts",
        "description": "Take a project's best published posts and write one fresh variation of each, in the brand voice. Returns drafts only; schedule the ones you keep with postcrow_schedule_post.",
        "x-openai-isConsequential": false,
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "project_id": {
                    "type": "string",
                    "description": "Project (brand) UUID from postcrow_list_projects. If omitted, the user's first project is used."
                  },
                  "limit": {
                    "type": "number",
                    "minimum": 1,
                    "maximum": 10,
                    "default": 3
                  },
                  "platforms": {
                    "type": "array",
                    "items": {
                      "type": "string",
                      "enum": [
                        "facebook",
                        "instagram",
                        "linkedin",
                        "twitter",
                        "telegram",
                        "dailymotion",
                        "mastodon",
                        "discord",
                        "bluesky",
                        "youtube",
                        "tiktok",
                        "threads",
                        "pinterest",
                        "reddit",
                        "devto",
                        "hashnode",
                        "snapchat",
                        "peertube",
                        "kick",
                        "twitch",
                        "tumblr",
                        "wordpress",
                        "wordpress_self",
                        "ghost",
                        "blogger",
                        "hatena",
                        "vimeo",
                        "soundcloud",
                        "deviantart",
                        "flickr",
                        "meetup",
                        "nextdoor",
                        "band",
                        "weibo",
                        "letterboxd"
                      ]
                    },
                    "description": "Defaults to each original's networks."
                  },
                  "language": {
                    "type": "string",
                    "enum": [
                      "EN",
                      "FR"
                    ]
                  }
                },
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The tool result as JSON.",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "400": {
            "description": "Invalid arguments."
          },
          "401": {
            "description": "Missing or invalid API key."
          },
          "402": {
            "description": "The HTTP API is part of the paid plans (Pro, Agency, Platform); the body carries upgrade_url."
          },
          "429": {
            "description": "Rate limited."
          }
        }
      }
    },
    "/api/v1/tools/postcrow_campaign": {
      "post": {
        "operationId": "postcrow_campaign",
        "summary": "Cross-brand campaign",
        "description": "One brief, many brands: for each project the post is written in that project's brand voice and scheduled (or saved as drafts with dry_run). Use start_at + stagger_minutes to space the brands out. Large campaigns keep running on the server; poll postcrow_campaign_status.",
        "x-openai-isConsequential": true,
        "parameters": [
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional, 1 to 255 visible ASCII characters (a UUID). A retry with the same key within 24 hours returns the first answer (header Idempotent-Replayed: true) instead of running again.",
            "schema": {
              "type": "string",
              "maxLength": 255
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "brief": {
                    "type": "string"
                  },
                  "project_ids": {
                    "type": "array",
                    "minItems": 1,
                    "items": {
                      "type": "string"
                    }
                  },
                  "platforms": {
                    "type": "array",
                    "items": {
                      "type": "string",
                      "enum": [
                        "facebook",
                        "instagram",
                        "linkedin",
                        "twitter",
                        "telegram",
                        "dailymotion",
                        "mastodon",
                        "discord",
                        "bluesky",
                        "youtube",
                        "tiktok",
                        "threads",
                        "pinterest",
                        "reddit",
                        "devto",
                        "hashnode",
                        "snapchat",
                        "peertube",
                        "kick",
                        "twitch",
                        "tumblr",
                        "wordpress",
                        "wordpress_self",
                        "ghost",
                        "blogger",
                        "hatena",
                        "vimeo",
                        "soundcloud",
                        "deviantart",
                        "flickr",
                        "meetup",
                        "nextdoor",
                        "band",
                        "weibo",
                        "letterboxd"
                      ]
                    },
                    "description": "Target networks. Each must be connected on the project: call postcrow_list_accounts first. Call postcrow_network_rules for each network's text limit and media rules.",
                    "minItems": 1
                  },
                  "scheduled_at": {
                    "type": "string",
                    "format": "date-time",
                    "description": "Same time for every brand. Exclusive with start_at."
                  },
                  "start_at": {
                    "type": "string",
                    "format": "date-time",
                    "description": "First brand's time when staggering."
                  },
                  "stagger_minutes": {
                    "type": "number",
                    "minimum": 0
                  },
                  "tone": {
                    "type": "string"
                  },
                  "language": {
                    "type": "string",
                    "enum": [
                      "EN",
                      "FR"
                    ]
                  },
                  "dry_run": {
                    "type": "boolean",
                    "description": "Return the drafts without scheduling."
                  },
                  "wait_seconds": {
                    "type": "number",
                    "minimum": 0,
                    "maximum": 60,
                    "description": "How long to wait for the result before returning a job id. Default 20."
                  }
                },
                "required": [
                  "brief",
                  "project_ids",
                  "platforms"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The tool result as JSON.",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "400": {
            "description": "Invalid arguments."
          },
          "401": {
            "description": "Missing or invalid API key."
          },
          "402": {
            "description": "The HTTP API is part of the paid plans (Pro, Agency, Platform); the body carries upgrade_url."
          },
          "409": {
            "description": "A request with the same Idempotency-Key is still running, or a conflict reported by the tool."
          },
          "422": {
            "description": "Idempotency-Key reused with another tool or body."
          },
          "429": {
            "description": "Rate limited."
          }
        }
      }
    },
    "/api/v1/tools/postcrow_campaign_status": {
      "post": {
        "operationId": "postcrow_campaign_status",
        "summary": "Campaign status",
        "description": "Progress and per-brand results of a campaign, or the list of recent campaigns when job_id is omitted.",
        "x-openai-isConsequential": false,
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "job_id": {
                    "type": "string"
                  }
                },
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The tool result as JSON.",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "400": {
            "description": "Invalid arguments."
          },
          "401": {
            "description": "Missing or invalid API key."
          },
          "402": {
            "description": "The HTTP API is part of the paid plans (Pro, Agency, Platform); the body carries upgrade_url."
          },
          "429": {
            "description": "Rate limited."
          }
        }
      }
    },
    "/api/v1/tools/postcrow_connect_link": {
      "post": {
        "operationId": "postcrow_connect_link",
        "summary": "Link to connect an account",
        "description": "Connect a social account to a brand. Returns a one-time link for the user to open in their browser (phone or computer): the network shows its own consent screen, the user presses Allow, and the account lands on that brand. You cannot press Allow for them, so send them the link and check postcrow_...",
        "x-openai-isConsequential": true,
        "parameters": [
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional, 1 to 255 visible ASCII characters (a UUID). A retry with the same key within 24 hours returns the first answer (header Idempotent-Replayed: true) instead of running again.",
            "schema": {
              "type": "string",
              "maxLength": 255
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "project_id": {
                    "type": "string",
                    "description": "Project (brand) UUID from postcrow_list_projects. If omitted, the user's first project is used."
                  },
                  "platform": {
                    "type": "string",
                    "enum": [
                      "facebook",
                      "instagram",
                      "linkedin",
                      "twitter",
                      "telegram",
                      "dailymotion",
                      "mastodon",
                      "discord",
                      "bluesky",
                      "youtube",
                      "tiktok",
                      "threads",
                      "pinterest",
                      "reddit",
                      "devto",
                      "hashnode",
                      "snapchat",
                      "peertube",
                      "kick",
                      "twitch",
                      "tumblr",
                      "wordpress",
                      "wordpress_self",
                      "ghost",
                      "blogger",
                      "hatena",
                      "vimeo",
                      "soundcloud",
                      "deviantart",
                      "flickr",
                      "meetup",
                      "nextdoor",
                      "band",
                      "weibo",
                      "letterboxd"
                    ],
                    "description": "The network to connect. Call postcrow_network_rules to see which are open on this server."
                  },
                  "instance": {
                    "type": "string",
                    "description": "Mastodon only: the user's server, e.g. mastodon.social."
                  }
                },
                "required": [
                  "platform"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The tool result as JSON.",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "400": {
            "description": "Invalid arguments."
          },
          "401": {
            "description": "Missing or invalid API key."
          },
          "402": {
            "description": "The HTTP API is part of the paid plans (Pro, Agency, Platform); the body carries upgrade_url."
          },
          "409": {
            "description": "A request with the same Idempotency-Key is still running, or a conflict reported by the tool."
          },
          "422": {
            "description": "Idempotency-Key reused with another tool or body."
          },
          "429": {
            "description": "Rate limited."
          }
        }
      }
    },
    "/api/v1/tools/postcrow_create_project": {
      "post": {
        "operationId": "postcrow_create_project",
        "summary": "Create a brand",
        "description": "Create a project (a brand). Accounts are then connected in the browser at https://postcrow.app/app/accounts; that step needs the user, because each network asks for consent.",
        "x-openai-isConsequential": true,
        "parameters": [
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional, 1 to 255 visible ASCII characters (a UUID). A retry with the same key within 24 hours returns the first answer (header Idempotent-Replayed: true) instead of running again.",
            "schema": {
              "type": "string",
              "maxLength": 255
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string"
                  },
                  "description": {
                    "type": "string"
                  },
                  "timezone": {
                    "type": "string",
                    "description": "IANA timezone, e.g. Europe/Paris."
                  },
                  "clone_from": {
                    "type": "string",
                    "description": "Project UUID to copy brand voice and timezone from."
                  }
                },
                "required": [
                  "name"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The tool result as JSON.",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "400": {
            "description": "Invalid arguments."
          },
          "401": {
            "description": "Missing or invalid API key."
          },
          "402": {
            "description": "The HTTP API is part of the paid plans (Pro, Agency, Platform); the body carries upgrade_url."
          },
          "409": {
            "description": "A request with the same Idempotency-Key is still running, or a conflict reported by the tool."
          },
          "422": {
            "description": "Idempotency-Key reused with another tool or body."
          },
          "429": {
            "description": "Rate limited."
          }
        }
      }
    },
    "/api/v1/tools/postcrow_project_settings": {
      "post": {
        "operationId": "postcrow_project_settings",
        "summary": "Brand settings",
        "description": "Read (only project_id) or change a project's name, description, timezone and weekly posting slots. Slots are local times in the project's timezone; posting_slots: [] clears them.",
        "x-openai-isConsequential": true,
        "parameters": [
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional, 1 to 255 visible ASCII characters (a UUID). A retry with the same key within 24 hours returns the first answer (header Idempotent-Replayed: true) instead of running again.",
            "schema": {
              "type": "string",
              "maxLength": 255
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "project_id": {
                    "type": "string"
                  },
                  "name": {
                    "type": "string"
                  },
                  "description": {
                    "type": "string"
                  },
                  "timezone": {
                    "type": "string"
                  },
                  "posting_slots": {
                    "type": "array",
                    "maxItems": 70,
                    "items": {
                      "type": "object",
                      "properties": {
                        "day": {
                          "type": "number",
                          "description": "0 = Sunday ... 6 = Saturday."
                        },
                        "hour": {
                          "type": "number",
                          "description": "0-23."
                        },
                        "minute": {
                          "type": "number",
                          "description": "0-59, default 0."
                        }
                      },
                      "required": [
                        "day",
                        "hour"
                      ],
                      "additionalProperties": false
                    }
                  }
                },
                "required": [
                  "project_id"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The tool result as JSON.",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "400": {
            "description": "Invalid arguments."
          },
          "401": {
            "description": "Missing or invalid API key."
          },
          "402": {
            "description": "The HTTP API is part of the paid plans (Pro, Agency, Platform); the body carries upgrade_url."
          },
          "409": {
            "description": "A request with the same Idempotency-Key is still running, or a conflict reported by the tool."
          },
          "422": {
            "description": "Idempotency-Key reused with another tool or body."
          },
          "429": {
            "description": "Rate limited."
          }
        }
      }
    },
    "/api/v1/tools/postcrow_next_slots": {
      "post": {
        "operationId": "postcrow_next_slots",
        "summary": "Next free slots",
        "description": "The next free posting slots of a project (taken slots skipped), as ISO timestamps. configured:false means the brand has no schedule.",
        "x-openai-isConsequential": false,
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "project_id": {
                    "type": "string"
                  },
                  "count": {
                    "type": "number",
                    "minimum": 1,
                    "maximum": 50
                  }
                },
                "required": [
                  "project_id"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The tool result as JSON.",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "400": {
            "description": "Invalid arguments."
          },
          "401": {
            "description": "Missing or invalid API key."
          },
          "402": {
            "description": "The HTTP API is part of the paid plans (Pro, Agency, Platform); the body carries upgrade_url."
          },
          "429": {
            "description": "Rate limited."
          }
        }
      }
    },
    "/api/v1/tools/postcrow_client_report": {
      "post": {
        "operationId": "postcrow_client_report",
        "summary": "Brand report",
        "description": "A project's report over a window: totals, per-network split, publishing rhythm, top posts and what is scheduled next. The same data a client sees on a shared report link.",
        "x-openai-isConsequential": false,
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "project_id": {
                    "type": "string"
                  },
                  "days": {
                    "type": "number",
                    "minimum": 7,
                    "maximum": 365,
                    "description": "Default 30."
                  }
                },
                "required": [
                  "project_id"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The tool result as JSON.",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "400": {
            "description": "Invalid arguments."
          },
          "401": {
            "description": "Missing or invalid API key."
          },
          "402": {
            "description": "The HTTP API is part of the paid plans (Pro, Agency, Platform); the body carries upgrade_url."
          },
          "429": {
            "description": "Rate limited."
          }
        }
      }
    },
    "/api/v1/tools/postcrow_client_link": {
      "post": {
        "operationId": "postcrow_client_link",
        "summary": "Client report links",
        "description": "Read-only report links for a client, no account needed. action=create returns the URL once (only a hash is stored), list shows existing links with view counts, revoke kills one immediately.",
        "x-openai-isConsequential": true,
        "parameters": [
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional, 1 to 255 visible ASCII characters (a UUID). A retry with the same key within 24 hours returns the first answer (header Idempotent-Replayed: true) instead of running again.",
            "schema": {
              "type": "string",
              "maxLength": 255
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "project_id": {
                    "type": "string"
                  },
                  "action": {
                    "type": "string",
                    "enum": [
                      "create",
                      "list",
                      "revoke"
                    ],
                    "description": "Default list."
                  },
                  "label": {
                    "type": "string",
                    "description": "For create: who it is for."
                  },
                  "lang": {
                    "type": "string",
                    "enum": [
                      "fr",
                      "en"
                    ],
                    "description": "For create: the client's language. Default fr."
                  },
                  "share_id": {
                    "type": "string",
                    "description": "For revoke."
                  }
                },
                "required": [
                  "project_id"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The tool result as JSON.",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "400": {
            "description": "Invalid arguments."
          },
          "401": {
            "description": "Missing or invalid API key."
          },
          "402": {
            "description": "The HTTP API is part of the paid plans (Pro, Agency, Platform); the body carries upgrade_url."
          },
          "409": {
            "description": "A request with the same Idempotency-Key is still running, or a conflict reported by the tool."
          },
          "422": {
            "description": "Idempotency-Key reused with another tool or body."
          },
          "429": {
            "description": "Rate limited."
          }
        }
      }
    },
    "/api/v1/tools/postcrow_webhooks": {
      "post": {
        "operationId": "postcrow_webhooks",
        "summary": "Outgoing webhooks",
        "description": "Outgoing webhooks (Platform plan): Postcrow POSTs a signed JSON event to your https URL when a post is published (post.published), partly published (post.partial) or failed (post.failed), or when an account needs reconnecting (account.disconnected). action=list (default) shows endpoints and wheth...",
        "x-openai-isConsequential": true,
        "parameters": [
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional, 1 to 255 visible ASCII characters (a UUID). A retry with the same key within 24 hours returns the first answer (header Idempotent-Replayed: true) instead of running again.",
            "schema": {
              "type": "string",
              "maxLength": 255
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "action": {
                    "type": "string",
                    "enum": [
                      "list",
                      "create",
                      "update",
                      "delete",
                      "test",
                      "deliveries",
                      "redeliver"
                    ],
                    "description": "Default list."
                  },
                  "webhook_id": {
                    "type": "string",
                    "description": "For update, delete, test, deliveries and redeliver."
                  },
                  "url": {
                    "type": "string",
                    "description": "For create or update: public https URL, default port."
                  },
                  "events": {
                    "type": "array",
                    "items": {
                      "type": "string",
                      "enum": [
                        "post.published",
                        "post.partial",
                        "post.failed",
                        "account.disconnected"
                      ]
                    },
                    "description": "For create or update. Default: every event."
                  },
                  "project_ids": {
                    "type": [
                      "array",
                      "null"
                    ],
                    "items": {
                      "type": "string"
                    },
                    "description": "For create or update: only these brands. Omit or null for every brand."
                  },
                  "description": {
                    "type": "string",
                    "description": "For create or update: a note for yourself."
                  },
                  "is_active": {
                    "type": "boolean",
                    "description": "For update: switch the endpoint off or back on."
                  },
                  "rotate_secret": {
                    "type": "boolean",
                    "description": "For update: issue a new signing secret (returned once); the old one stops working at once."
                  },
                  "delivery_id": {
                    "type": "string",
                    "description": "For redeliver."
                  },
                  "limit": {
                    "type": "number",
                    "minimum": 1,
                    "maximum": 100,
                    "description": "For deliveries. Default 20."
                  }
                },
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The tool result as JSON.",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "400": {
            "description": "Invalid arguments."
          },
          "401": {
            "description": "Missing or invalid API key."
          },
          "402": {
            "description": "The HTTP API is part of the paid plans (Pro, Agency, Platform); the body carries upgrade_url."
          },
          "409": {
            "description": "A request with the same Idempotency-Key is still running, or a conflict reported by the tool."
          },
          "422": {
            "description": "Idempotency-Key reused with another tool or body."
          },
          "429": {
            "description": "Rate limited."
          }
        }
      }
    }
  },
  "webhooks": {
    "post.published": {
      "post": {
        "summary": "post.published",
        "description": "A post went out on every network it targeted. Signed: X-Postcrow-Signature is v1=<hex HMAC-SHA256 of \"<X-Postcrow-Timestamp>.<raw body>\"> with the endpoint secret. Retried with backoff up to 7 times on timeouts, 408, 429 and 5xx; dedupe on X-Postcrow-Event-Id.",
        "parameters": [
          {
            "name": "X-Postcrow-Event",
            "in": "header",
            "schema": {
              "type": "string",
              "const": "post.published"
            }
          },
          {
            "name": "X-Postcrow-Event-Id",
            "in": "header",
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "X-Postcrow-Timestamp",
            "in": "header",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "X-Postcrow-Signature",
            "in": "header",
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "id": {
                    "type": "string",
                    "format": "uuid"
                  },
                  "event": {
                    "type": "string",
                    "const": "post.published"
                  },
                  "created_at": {
                    "type": "string",
                    "format": "date-time"
                  },
                  "data": {
                    "type": "object",
                    "properties": {
                      "post": {
                        "type": "object",
                        "properties": {
                          "id": {
                            "type": "string"
                          },
                          "project_id": {
                            "type": "string"
                          },
                          "status": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "content": {
                            "type": "string"
                          },
                          "platforms": {
                            "type": "array",
                            "items": {
                              "type": "string"
                            }
                          },
                          "media_urls": {
                            "type": "array",
                            "items": {
                              "type": "string"
                            }
                          },
                          "scheduled_at": {
                            "type": [
                              "string",
                              "null"
                            ],
                            "format": "date-time"
                          },
                          "published_at": {
                            "type": [
                              "string",
                              "null"
                            ],
                            "format": "date-time"
                          }
                        }
                      },
                      "networks": {
                        "type": "object",
                        "additionalProperties": {
                          "type": "object",
                          "properties": {
                            "success": {
                              "type": "boolean"
                            },
                            "url": {
                              "type": [
                                "string",
                                "null"
                              ]
                            },
                            "post_id": {
                              "type": [
                                "string",
                                "null"
                              ]
                            },
                            "error": {
                              "type": [
                                "string",
                                "null"
                              ]
                            },
                            "warning": {
                              "type": [
                                "string",
                                "null"
                              ]
                            }
                          }
                        }
                      },
                      "error": {
                        "type": "string"
                      }
                    }
                  }
                }
              }
            }
          }
        },
        "responses": {
          "2XX": {
            "description": "Received. Answer within 5 seconds."
          }
        }
      }
    },
    "post.partial": {
      "post": {
        "summary": "post.partial",
        "description": "A post went out on some networks and failed on others. Signed: X-Postcrow-Signature is v1=<hex HMAC-SHA256 of \"<X-Postcrow-Timestamp>.<raw body>\"> with the endpoint secret. Retried with backoff up to 7 times on timeouts, 408, 429 and 5xx; dedupe on X-Postcrow-Event-Id.",
        "parameters": [
          {
            "name": "X-Postcrow-Event",
            "in": "header",
            "schema": {
              "type": "string",
              "const": "post.partial"
            }
          },
          {
            "name": "X-Postcrow-Event-Id",
            "in": "header",
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "X-Postcrow-Timestamp",
            "in": "header",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "X-Postcrow-Signature",
            "in": "header",
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "id": {
                    "type": "string",
                    "format": "uuid"
                  },
                  "event": {
                    "type": "string",
                    "const": "post.partial"
                  },
                  "created_at": {
                    "type": "string",
                    "format": "date-time"
                  },
                  "data": {
                    "type": "object",
                    "properties": {
                      "post": {
                        "type": "object",
                        "properties": {
                          "id": {
                            "type": "string"
                          },
                          "project_id": {
                            "type": "string"
                          },
                          "status": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "content": {
                            "type": "string"
                          },
                          "platforms": {
                            "type": "array",
                            "items": {
                              "type": "string"
                            }
                          },
                          "media_urls": {
                            "type": "array",
                            "items": {
                              "type": "string"
                            }
                          },
                          "scheduled_at": {
                            "type": [
                              "string",
                              "null"
                            ],
                            "format": "date-time"
                          },
                          "published_at": {
                            "type": [
                              "string",
                              "null"
                            ],
                            "format": "date-time"
                          }
                        }
                      },
                      "networks": {
                        "type": "object",
                        "additionalProperties": {
                          "type": "object",
                          "properties": {
                            "success": {
                              "type": "boolean"
                            },
                            "url": {
                              "type": [
                                "string",
                                "null"
                              ]
                            },
                            "post_id": {
                              "type": [
                                "string",
                                "null"
                              ]
                            },
                            "error": {
                              "type": [
                                "string",
                                "null"
                              ]
                            },
                            "warning": {
                              "type": [
                                "string",
                                "null"
                              ]
                            }
                          }
                        }
                      },
                      "error": {
                        "type": "string"
                      }
                    }
                  }
                }
              }
            }
          }
        },
        "responses": {
          "2XX": {
            "description": "Received. Answer within 5 seconds."
          }
        }
      }
    },
    "post.failed": {
      "post": {
        "summary": "post.failed",
        "description": "A post failed on every network, after the automatic retries. Signed: X-Postcrow-Signature is v1=<hex HMAC-SHA256 of \"<X-Postcrow-Timestamp>.<raw body>\"> with the endpoint secret. Retried with backoff up to 7 times on timeouts, 408, 429 and 5xx; dedupe on X-Postcrow-Event-Id.",
        "parameters": [
          {
            "name": "X-Postcrow-Event",
            "in": "header",
            "schema": {
              "type": "string",
              "const": "post.failed"
            }
          },
          {
            "name": "X-Postcrow-Event-Id",
            "in": "header",
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "X-Postcrow-Timestamp",
            "in": "header",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "X-Postcrow-Signature",
            "in": "header",
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "id": {
                    "type": "string",
                    "format": "uuid"
                  },
                  "event": {
                    "type": "string",
                    "const": "post.failed"
                  },
                  "created_at": {
                    "type": "string",
                    "format": "date-time"
                  },
                  "data": {
                    "type": "object",
                    "properties": {
                      "post": {
                        "type": "object",
                        "properties": {
                          "id": {
                            "type": "string"
                          },
                          "project_id": {
                            "type": "string"
                          },
                          "status": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "content": {
                            "type": "string"
                          },
                          "platforms": {
                            "type": "array",
                            "items": {
                              "type": "string"
                            }
                          },
                          "media_urls": {
                            "type": "array",
                            "items": {
                              "type": "string"
                            }
                          },
                          "scheduled_at": {
                            "type": [
                              "string",
                              "null"
                            ],
                            "format": "date-time"
                          },
                          "published_at": {
                            "type": [
                              "string",
                              "null"
                            ],
                            "format": "date-time"
                          }
                        }
                      },
                      "networks": {
                        "type": "object",
                        "additionalProperties": {
                          "type": "object",
                          "properties": {
                            "success": {
                              "type": "boolean"
                            },
                            "url": {
                              "type": [
                                "string",
                                "null"
                              ]
                            },
                            "post_id": {
                              "type": [
                                "string",
                                "null"
                              ]
                            },
                            "error": {
                              "type": [
                                "string",
                                "null"
                              ]
                            },
                            "warning": {
                              "type": [
                                "string",
                                "null"
                              ]
                            }
                          }
                        }
                      },
                      "error": {
                        "type": "string"
                      }
                    }
                  }
                }
              }
            }
          }
        },
        "responses": {
          "2XX": {
            "description": "Received. Answer within 5 seconds."
          }
        }
      }
    },
    "account.disconnected": {
      "post": {
        "summary": "account.disconnected",
        "description": "A connected account can no longer publish (token expired or revoked) and needs reconnecting. Signed: X-Postcrow-Signature is v1=<hex HMAC-SHA256 of \"<X-Postcrow-Timestamp>.<raw body>\"> with the endpoint secret. Retried with backoff up to 7 times on timeouts, 408, 429 and 5xx; dedupe on X-Postcrow-Event-Id.",
        "parameters": [
          {
            "name": "X-Postcrow-Event",
            "in": "header",
            "schema": {
              "type": "string",
              "const": "account.disconnected"
            }
          },
          {
            "name": "X-Postcrow-Event-Id",
            "in": "header",
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "X-Postcrow-Timestamp",
            "in": "header",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "X-Postcrow-Signature",
            "in": "header",
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "id": {
                    "type": "string",
                    "format": "uuid"
                  },
                  "event": {
                    "type": "string",
                    "const": "account.disconnected"
                  },
                  "created_at": {
                    "type": "string",
                    "format": "date-time"
                  },
                  "data": {
                    "type": "object",
                    "properties": {
                      "account": {
                        "type": "object",
                        "properties": {
                          "id": {
                            "type": "string"
                          },
                          "project_id": {
                            "type": "string"
                          },
                          "platform": {
                            "type": "string"
                          },
                          "name": {
                            "type": "string"
                          }
                        }
                      },
                      "reconnect_url": {
                        "type": "string"
                      }
                    }
                  }
                }
              }
            }
          }
        },
        "responses": {
          "2XX": {
            "description": "Received. Answer within 5 seconds."
          }
        }
      }
    }
  }
}