{
  "openapi": "3.0.1",
  "info": {
    "title": "FDA Device Establishment Lookup",
    "description": "One record per FDA-registered medical device establishment matching your firm, number, product code, device or country search, with its listed devices and their 510(k)/De Novo/PMA numbers. Public openFDA source.",
    "version": "0.1",
    "x-build-id": "C9DQrDVFrAr6BK1bK"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/sovereign_workspace~fda-device-establishment-lookup/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-sovereign_workspace-fda-device-establishment-lookup",
        "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/sovereign_workspace~fda-device-establishment-lookup/runs": {
      "post": {
        "operationId": "runs-sync-sovereign_workspace-fda-device-establishment-lookup",
        "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/sovereign_workspace~fda-device-establishment-lookup/run-sync": {
      "post": {
        "operationId": "run-sync-sovereign_workspace-fda-device-establishment-lookup",
        "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": {
          "profile": {
            "title": "Operator profile",
            "enum": [
              "standard",
              "smoke"
            ],
            "type": "string",
            "description": "Named config preset applied at start. Any field you set explicitly below overrides the preset."
          },
          "firm_names": {
            "title": "Firm names",
            "type": "array",
            "description": "Company names or phrases, matched (case-insensitive, whole words) against the establishment name and its owner/operator firm name, e.g. medtronic, smith & nephew. Up to 5.",
            "items": {
              "type": "string"
            }
          },
          "registration_numbers": {
            "title": "Registration or FEI numbers",
            "type": "array",
            "description": "FDA establishment registration numbers or FEI numbers (5-10 digits). Up to 200.",
            "items": {
              "type": "string"
            }
          },
          "product_codes": {
            "title": "Product codes",
            "type": "array",
            "description": "Three-letter FDA device product codes (e.g. DXY, FLL). Only establishments listing a device under one of these codes are returned. Up to 30.",
            "items": {
              "type": "string"
            }
          },
          "device_classes": {
            "title": "Device classes",
            "type": "array",
            "description": "Only listings of devices in these classes. Combined with product codes or a listing window, one listed device must satisfy all of them.",
            "items": {
              "type": "string",
              "enum": [
                "1",
                "2",
                "3",
                "U",
                "N",
                "F"
              ],
              "enumTitles": [
                "Class I",
                "Class II",
                "Class III",
                "Unclassified",
                "Not classified",
                "HDE"
              ]
            }
          },
          "proprietary_names": {
            "title": "Proprietary (brand) names",
            "type": "array",
            "description": "Brand names or model phrases matched against the listing's proprietary names, e.g. lifevest. Up to 5.",
            "items": {
              "type": "string"
            }
          },
          "premarket_numbers": {
            "title": "510(k) / De Novo / PMA numbers",
            "type": "array",
            "description": "Find the establishments whose listings cite these premarket numbers, e.g. K103680, DEN220039, P990040. Up to 50.",
            "items": {
              "type": "string"
            }
          },
          "countries": {
            "title": "Countries (ISO codes)",
            "type": "array",
            "description": "Two-letter ISO country codes of the establishment, e.g. US, DE, CN, MX. Up to 30.",
            "items": {
              "type": "string"
            }
          },
          "states": {
            "title": "US states",
            "type": "array",
            "description": "Two-letter US state codes of the establishment, e.g. OH, CA. Up to 60.",
            "items": {
              "type": "string"
            }
          },
          "establishment_types": {
            "title": "Establishment operations",
            "type": "array",
            "description": "Only listings where the establishment performs one of these operations (manufacturer, contract manufacturer, sterilizer…). Narrows another filter; not a search on its own.",
            "items": {
              "type": "string",
              "enum": [
                "manufacturer",
                "contract_manufacturer",
                "repackager_relabeler",
                "specification_developer",
                "contract_sterilizer",
                "foreign_exporter",
                "complaint_file_establishment",
                "remanufacturer",
                "us_manufacturer_export_only",
                "single_use_reprocessor",
                "foreign_private_label_distributor"
              ],
              "enumTitles": [
                "Manufacturer",
                "Contract manufacturer",
                "Repackager / relabeler",
                "Specification developer",
                "Contract sterilizer",
                "Foreign exporter",
                "Complaint file establishment",
                "Remanufacturer",
                "US manufacturer, export only",
                "Single-use device reprocessor",
                "Foreign private label distributor"
              ]
            }
          },
          "listed_since_days": {
            "title": "Listed in the last N days",
            "minimum": 0,
            "maximum": 365,
            "type": "integer",
            "description": "Only devices whose listing was created in the last N days (openFDA notes the listing date may be unreliable); 0 = any date. On its own it's a new-listings feed. Not combinable with changes-only mode.",
            "default": 0
          },
          "changes_only": {
            "title": "Changes only (scheduled watch)",
            "type": "boolean",
            "description": "Keep a snapshot of this search in a named key-value store in your account and return only establishments that are new, changed (listings added or removed, status, operations, registration year) or gone since the previous run. The first run records the baseline and charges nothing. A watch may cover up to 15,000 listings.",
            "default": false
          },
          "allow_mass_changes": {
            "title": "Allow mass changes",
            "type": "boolean",
            "description": "Changes-only safety guard: if over 20% of 25 or more watched establishments change or vanish at once, the run stops without charging (usually an openFDA data problem). Turn this on to accept it, e.g. after the annual registration renewal.",
            "default": false
          },
          "api_key": {
            "title": "openFDA API key (optional)",
            "type": "string",
            "description": "Optional free openFDA key. Without one, openFDA allows 1,000 requests per day per IP, and Apify IPs are shared."
          },
          "limit": {
            "title": "Max establishments",
            "type": "integer",
            "description": "Maximum number of establishment records (or changes) to return per run (up to 1000).",
            "default": 100
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}