{
  "openapi": "3.0.1",
  "info": {
    "title": "Hugging Face Hub Search: Models, Datasets, Spaces",
    "description": "Search the Hugging Face Hub for models, datasets, Spaces and daily papers. Get flat rows with downloads, likes, task, license, language, tags and dates. Filter by owner, task, license and language. Public metadata, $3.00 per 1,000 results.",
    "version": "1.0",
    "x-build-id": "zWqGvDR85vjkgWK1p"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/conserving_celerytop~huggingface-hub-search-api/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-conserving_celerytop-huggingface-hub-search-api",
        "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/conserving_celerytop~huggingface-hub-search-api/runs": {
      "post": {
        "operationId": "runs-sync-conserving_celerytop-huggingface-hub-search-api",
        "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/conserving_celerytop~huggingface-hub-search-api/run-sync": {
      "post": {
        "operationId": "run-sync-conserving_celerytop-huggingface-hub-search-api",
        "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": {
          "resource": {
            "title": "Resource type",
            "enum": [
              "models",
              "datasets",
              "spaces",
              "papers"
            ],
            "type": "string",
            "description": "Choose what to list: models, datasets, Spaces or daily papers.",
            "default": "models"
          },
          "searchQuery": {
            "title": "Search text",
            "maxLength": 250,
            "type": "string",
            "description": "Type words from the repository name, for example llama or sentiment. For papers, type a topic, for example diffusion. Leave it empty to list the top results for your sort order."
          },
          "maxItems": {
            "title": "Maximum results",
            "minimum": 1,
            "maximum": 10000,
            "type": "integer",
            "description": "Set how many rows to return, from 1 to 10,000. Each saved row is one charged result. A paper search returns up to 120 rows.",
            "default": 100
          },
          "owner": {
            "title": "Owner",
            "type": "string",
            "description": "Enter an owner namespace to list its repositories, for example meta-llama or google. Applies to models, datasets and Spaces."
          },
          "task": {
            "title": "Task",
            "type": "string",
            "description": "Enter a task name, for example text-generation or text-classification. For models this is the pipeline tag, for datasets the task category."
          },
          "license": {
            "title": "License",
            "type": "string",
            "description": "Enter a license id, for example apache-2.0 or mit."
          },
          "language": {
            "title": "Language",
            "type": "string",
            "description": "Enter a language code, for example en or de. Applies to models and datasets."
          },
          "library": {
            "title": "Library",
            "type": "string",
            "description": "Enter a library name, for example transformers or diffusers. Applies to models."
          },
          "spaceSdk": {
            "title": "Space SDK",
            "enum": [
              "gradio",
              "streamlit",
              "docker",
              "static"
            ],
            "type": "string",
            "description": "Choose the SDK a Space is built with. Applies to Spaces."
          },
          "sortBy": {
            "title": "Sort by",
            "enum": [
              "default",
              "downloads",
              "likes",
              "trendingScore",
              "createdAt",
              "lastModified"
            ],
            "type": "string",
            "description": "Choose the ranking. The default is downloads for models and datasets, likes for Spaces and the Hub's newest-first order for papers. Spaces rank by likes, trending score, created or modified. Papers rank by trending score or by the Hub's newest-first order.",
            "default": "default"
          },
          "tags": {
            "title": "Tags",
            "maxItems": 10,
            "type": "array",
            "description": "Add Hub tags to narrow the list, for example task_categories:text-classification or size_categories:1M<n<10M. Rows match all tags.",
            "items": {
              "type": "string"
            }
          },
          "paperDate": {
            "title": "Paper date",
            "pattern": "^\\d{4}-\\d{2}-\\d{2}$",
            "type": "string",
            "description": "Enter a day as YYYY-MM-DD to list the papers featured on that day, for example 2026-10-01. Applies to papers when the search text is empty."
          },
          "onlyNew": {
            "title": "Only new since the last run",
            "type": "boolean",
            "description": "Return only items that this monitor has not delivered before. The first run returns everything and becomes the baseline. Use it with a daily schedule.",
            "default": false
          },
          "monitorName": {
            "title": "Monitor name",
            "type": "string",
            "description": "Names the memory of this monitor. Use one name per saved task, so two tasks never share their memory.",
            "default": "default"
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}