{
  "openapi": "3.0.1",
  "info": {
    "title": "OpenSea + Magic Eden NFT Scraper",
    "description": "Scrape NFT collections, listings, sales, activity feeds, and individual NFT metadata from OpenSea (Ethereum, Polygon, Base, etc.) and Magic Eden (Solana). Floor prices, volume, owners, traits, current listings, recent sales/bids, public API, no login required.",
    "version": "1.0",
    "x-build-id": "G0I1OmInXARBVvCnT"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/crawlerbros~opensea-magiceden-nft/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-crawlerbros-opensea-magiceden-nft",
        "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/crawlerbros~opensea-magiceden-nft/runs": {
      "post": {
        "operationId": "runs-sync-crawlerbros-opensea-magiceden-nft",
        "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/crawlerbros~opensea-magiceden-nft/run-sync": {
      "post": {
        "operationId": "run-sync-crawlerbros-opensea-magiceden-nft",
        "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",
        "required": [
          "platform",
          "mode"
        ],
        "properties": {
          "platform": {
            "title": "Platform",
            "enum": [
              "opensea",
              "magiceden"
            ],
            "type": "string",
            "description": "Which NFT marketplace to scrape.",
            "default": "magiceden"
          },
          "mode": {
            "title": "Mode",
            "enum": [
              "byCollection",
              "collectionStats",
              "listingsByCollection",
              "salesByCollection",
              "activitiesByCollection",
              "byNft",
              "searchCollections",
              "popularCollections",
              "byUrl"
            ],
            "type": "string",
            "description": "What to scrape. `popularCollections` (Magic Eden only) needs no auth and is the recommended default.",
            "default": "popularCollections"
          },
          "collectionSlugs": {
            "title": "Collection slugs / symbols (mode=byCollection, collectionStats, listingsByCollection, salesByCollection, activitiesByCollection)",
            "type": "array",
            "description": "OpenSea collection slugs (e.g. `azuki`, `boredapeyachtclub`) or Magic Eden collection symbols (e.g. `okay_bears`, `degenerate_ape_academy`). For `byCollection`, the underlying API serves slug-keyed metadata.",
            "default": [
              "azuki"
            ],
            "items": {
              "type": "string"
            }
          },
          "chain": {
            "title": "Chain (mode=byNft on OpenSea)",
            "enum": [
              "ethereum",
              "matic",
              "base",
              "arbitrum",
              "arbitrum_nova",
              "optimism",
              "avalanche",
              "klaytn",
              "bsc",
              "zora",
              "blast",
              "sei",
              "solana"
            ],
            "type": "string",
            "description": "Blockchain network for OpenSea NFT lookup. Magic Eden uses Solana (no chain param needed).",
            "default": "ethereum"
          },
          "contractAddress": {
            "title": "Contract address (mode=byNft, OpenSea)",
            "type": "string",
            "description": "Smart-contract address holding the NFT (e.g. `0xed5af388653567af2f388e6224dc7c4b3241c544` for Azuki)."
          },
          "tokenId": {
            "title": "Token ID (mode=byNft, OpenSea)",
            "type": "string",
            "description": "Token ID inside the contract (numeric string, e.g. `9605`)."
          },
          "tokenMint": {
            "title": "Token mint (mode=byNft, Magic Eden / Solana)",
            "type": "string",
            "description": "Solana token mint address for the NFT."
          },
          "searchQuery": {
            "title": "Search query (mode=searchCollections — informational; APIs return top collections regardless)",
            "type": "string",
            "description": "Optional free-text label. Both upstreams return ranked collection lists rather than full-text search; this field is logged but not sent to the API."
          },
          "sortBy": {
            "title": "Sort order (mode=searchCollections, OpenSea)",
            "enum": [
              "market_cap",
              "seven_day_volume",
              "one_day_volume",
              "num_owners",
              "created_date"
            ],
            "type": "string",
            "description": "Sort key for OpenSea collections list. Magic Eden popular feed uses `timeRange` instead.",
            "default": "market_cap"
          },
          "timeRange": {
            "title": "Time range (mode=popularCollections, Magic Eden)",
            "enum": [
              "1h",
              "1d",
              "7d",
              "30d"
            ],
            "type": "string",
            "description": "Window for Magic Eden popular-collections ranking.",
            "default": "1d"
          },
          "eventType": {
            "title": "Event type (mode=activitiesByCollection — Magic Eden / mode=salesByCollection — OpenSea)",
            "enum": [
              "sale",
              "listing",
              "delisting",
              "bid",
              "cancelBid",
              "all"
            ],
            "type": "string",
            "description": "Filter activity feed to a single event type.",
            "default": "sale"
          },
          "urls": {
            "title": "URLs (mode=byUrl)",
            "type": "array",
            "description": "Paste opensea.io collection / item URLs or magiceden.io collection / item URLs. The actor auto-detects platform and entity type.",
            "default": [
              "https://magiceden.io/marketplace/okay_bears",
              "https://opensea.io/collection/azuki"
            ],
            "items": {
              "type": "string"
            }
          },
          "openseaApiKey": {
            "title": "OpenSea API key (optional but recommended)",
            "type": "string",
            "description": "Free API key from https://docs.opensea.io/reference/api-keys. Without one, only `byCollection` and `collectionStats` modes work on OpenSea (other modes return 401). Magic Eden does NOT need a key."
          },
          "maxItems": {
            "title": "Max items",
            "minimum": 1,
            "maximum": 5000,
            "type": "integer",
            "description": "Hard cap on emitted records across all modes.",
            "default": 50
          },
          "autoEscalateOnBlock": {
            "title": "Auto-escalate to Apify proxy on block",
            "type": "boolean",
            "description": "If true (default), the actor engages Apify proxy on HTTP 429 / 5xx anti-bot blocks. Both APIs work cleanly from datacenter IPs in normal conditions.",
            "default": true
          },
          "proxyGroups": {
            "title": "Apify proxy groups (used on auto-escalation)",
            "type": "array",
            "description": "Apify proxy groups to engage on auto-escalation. Empty = datacenter (default), then residential fallback.",
            "default": [],
            "items": {
              "type": "string"
            }
          }
        }
      },
      "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
                  }
                }
              },
              "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}