{
  "openapi": "3.0.1",
  "info": {
    "title": "Activepieces Pieces & Flow Templates Scraper — Usage & JSON",
    "description": "Extract 770+ Activepieces integrations (live usage counts, actions, triggers, auth) and 420+ official workflow templates with importable flow JSON. Pure HTTP/JSON.",
    "version": "1.0",
    "x-build-id": "aEPq9cwFveEIlSwgH"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/gridline-labs~activepieces-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-gridline-labs-activepieces-scraper",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor, waits for its completion, and returns Actor's dataset items in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/acts/gridline-labs~activepieces-scraper/runs": {
      "post": {
        "operationId": "runs-sync-gridline-labs-activepieces-scraper",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor and returns information about the initiated run in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/runsResponseSchema"
                }
              }
            }
          }
        }
      }
    },
    "/acts/gridline-labs~activepieces-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-gridline-labs-activepieces-scraper",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor, waits for completion, and returns the OUTPUT from Key-value store in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "inputSchema": {
        "type": "object",
        "properties": {
          "mode": {
            "title": "Extraction Mode",
            "enum": [
              "pieces",
              "templates",
              "both"
            ],
            "type": "string",
            "description": "Choose whether to extract Activepieces integration Pieces, official Flow Templates, or both in one run.",
            "default": "pieces"
          },
          "searchQuery": {
            "title": "Search Keyword",
            "type": "string",
            "description": "Optional case-insensitive keyword filter matching name, displayName, description, summary, authors, or piece tags (e.g. 'AI', 'Slack', 'CRM', 'Shopify'). Leave empty for the full catalog.",
            "default": ""
          },
          "categories": {
            "title": "Category Filter",
            "type": "array",
            "description": "Optional list of Activepieces categories (e.g. 'ARTIFICIAL_INTELLIGENCE', 'COMMUNICATION', 'SALES_AND_CRM', 'PRODUCTIVITY', 'DEVELOPER_TOOLS', 'COMMERCE').",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "pieceNames": {
            "title": "Specific Piece Names or Slugs",
            "type": "array",
            "description": "Optional list of piece slugs or short names (e.g. 'slack', 'openai', '@activepieces/piece-notion'). In pieces mode, returns matching pieces; in templates mode, returns templates using any listed piece.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "minProjectUsage": {
            "title": "Minimum Project Usage (Pieces)",
            "minimum": 0,
            "type": "integer",
            "description": "Only include Pieces used in at least this many Activepieces projects (pieces mode). Set 0 for all.",
            "default": 0
          },
          "excludeDeprecated": {
            "title": "Exclude Deprecated Pieces",
            "type": "boolean",
            "description": "Skip Pieces flagged as deprecated in the official registry.",
            "default": true
          },
          "sortBy": {
            "title": "Sort Order",
            "enum": [
              "usage",
              "updated",
              "created",
              "actions",
              "name"
            ],
            "type": "string",
            "description": "How to sort matched results before applying maxResults.",
            "default": "usage"
          },
          "includePieceDetails": {
            "title": "Include Full Actions & Triggers Schema (Pieces)",
            "type": "boolean",
            "description": "Fetches each Piece's full manifest from /api/v1/pieces/{name} to include every action name, trigger name, description, auth requirement, and input property list. Triggers the piece-actions-detail event ($0.003/piece).",
            "default": false
          },
          "includeFlowJson": {
            "title": "Include Full Importable Flow JSON (Templates)",
            "type": "boolean",
            "description": "Includes the full Activepieces flows[] JSON blueprint inside each template record (templates/both mode). No extra charge beyond catalog-item.",
            "default": true
          },
          "onlyNew": {
            "title": "Monitor Mode (Only New Items)",
            "type": "boolean",
            "description": "Persist seen IDs across scheduled runs and output only newly added Pieces or Templates. Previously seen items are skipped at $0 cost.",
            "default": false
          },
          "monitorKey": {
            "title": "Monitor State Key",
            "type": "string",
            "description": "Named state key used when onlyNew is enabled so independent schedules don't collide.",
            "default": "default"
          },
          "maxResults": {
            "title": "Max Results",
            "minimum": 1,
            "maximum": 5000,
            "type": "integer",
            "description": "Maximum number of matched records to deliver to the dataset.",
            "default": 50
          }
        }
      },
      "runsResponseSchema": {
        "type": "object",
        "properties": {
          "data": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string"
              },
              "actId": {
                "type": "string"
              },
              "userId": {
                "type": "string"
              },
              "startedAt": {
                "type": "string",
                "format": "date-time",
                "example": "2025-01-08T00:00:00.000Z"
              },
              "finishedAt": {
                "type": "string",
                "format": "date-time",
                "example": "2025-01-08T00:00:00.000Z"
              },
              "status": {
                "type": "string",
                "example": "READY"
              },
              "meta": {
                "type": "object",
                "properties": {
                  "origin": {
                    "type": "string",
                    "example": "API"
                  },
                  "userAgent": {
                    "type": "string"
                  }
                }
              },
              "stats": {
                "type": "object",
                "properties": {
                  "inputBodyLen": {
                    "type": "integer",
                    "example": 2000
                  },
                  "rebootCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "restartCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "resurrectCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "computeUnits": {
                    "type": "integer",
                    "example": 0
                  }
                }
              },
              "options": {
                "type": "object",
                "properties": {
                  "build": {
                    "type": "string",
                    "example": "latest"
                  },
                  "timeoutSecs": {
                    "type": "integer",
                    "example": 300
                  },
                  "memoryMbytes": {
                    "type": "integer",
                    "example": 1024
                  },
                  "diskMbytes": {
                    "type": "integer",
                    "example": 2048
                  }
                }
              },
              "buildId": {
                "type": "string"
              },
              "defaultKeyValueStoreId": {
                "type": "string"
              },
              "defaultDatasetId": {
                "type": "string"
              },
              "defaultRequestQueueId": {
                "type": "string"
              },
              "buildNumber": {
                "type": "string",
                "example": "1.0.0"
              },
              "containerUrl": {
                "type": "string"
              },
              "usage": {
                "type": "object",
                "properties": {
                  "ACTOR_COMPUTE_UNITS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_WRITES": {
                    "type": "integer",
                    "example": 1
                  },
                  "KEY_VALUE_STORE_LISTS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_INTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_EXTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_SERPS": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_UNBLOCKER_UNITS": {
                    "type": "integer",
                    "example": 0
                  }
                }
              },
              "usageTotalUsd": {
                "type": "number",
                "example": 0.00005
              },
              "usageUsd": {
                "type": "object",
                "properties": {
                  "ACTOR_COMPUTE_UNITS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_WRITES": {
                    "type": "number",
                    "example": 0.00005
                  },
                  "KEY_VALUE_STORE_LISTS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_INTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_EXTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_SERPS": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_UNBLOCKER_UNITS": {
                    "type": "integer",
                    "example": 0
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}