{
  "openapi": "3.0.1",
  "info": {
    "title": "LEI Lookup API: Legal Entity Identifiers & Company Ownership",
    "description": "LEI lookup and LEI search API for the GLEIF Global LEI Index: legal entity identifier records with legal name, register number, addresses, LEI status and renewal date, BICs, and direct and ultimate parent companies. Find subsidiaries. Monitor mode for changes. No API key.",
    "version": "0.1",
    "x-build-id": "wBdRwoXROpqTxecMq"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/yourevenings~lei-company-lookup/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-yourevenings-lei-company-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/yourevenings~lei-company-lookup/runs": {
      "post": {
        "operationId": "runs-sync-yourevenings-lei-company-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/yourevenings~lei-company-lookup/run-sync": {
      "post": {
        "operationId": "run-sync-yourevenings-lei-company-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",
        "required": [
          "mode"
        ],
        "properties": {
          "mode": {
            "title": "Mode",
            "enum": [
              "lookup",
              "search",
              "subsidiaries"
            ],
            "type": "string",
            "description": "<b>Look up LEIs</b> returns the records for the LEIs you list. <b>Search</b> finds records by name, country, dates or status. <b>Subsidiaries</b> lists the entities that report a parent LEI as their direct or ultimate parent.",
            "default": "lookup"
          },
          "leis": {
            "title": "LEIs",
            "type": "array",
            "description": "For <b>Look up LEIs</b>: up to 500 LEIs (20 characters). Invalid LEIs get a free status row.",
            "items": {
              "type": "string"
            }
          },
          "name": {
            "title": "Name",
            "type": "string",
            "description": "For <b>Search</b>: words in the legal or other names (full-text). Turn on 'Exact legal name' to match the legal name exactly."
          },
          "exactName": {
            "title": "Exact legal name",
            "type": "boolean",
            "description": "Match the legal name exactly instead of full-text.",
            "default": false
          },
          "countries": {
            "title": "Legal address countries",
            "type": "array",
            "description": "2-letter ISO codes, e.g. <code>GB</code>, <code>DE</code>, <code>US</code>.",
            "items": {
              "type": "string"
            }
          },
          "headquartersCountries": {
            "title": "Headquarters countries",
            "type": "array",
            "description": "2-letter ISO codes of the headquarters address.",
            "items": {
              "type": "string"
            }
          },
          "city": {
            "title": "Legal address city",
            "type": "string",
            "description": "Exact city name as recorded, e.g. <code>London</code>."
          },
          "registeredWithinDays": {
            "title": "LEI first issued in the last N days",
            "minimum": 0,
            "type": "integer",
            "description": "Only LEIs first registered in the last N days (newly registered entities). 0 turns this off.",
            "default": 0
          },
          "registeredSince": {
            "title": "LEI first issued since (YYYY-MM-DD)",
            "type": "string",
            "description": "Overrides 'first issued in the last N days'."
          },
          "renewalDueWithinDays": {
            "title": "Renewal due within N days",
            "minimum": 0,
            "type": "integer",
            "description": "Only LEIs whose next renewal date is between today and N days from now. 0 turns this off.",
            "default": 0
          },
          "renewalDueFrom": {
            "title": "Renewal due from (YYYY-MM-DD)",
            "type": "string",
            "description": "Optional start of a renewal-date range."
          },
          "renewalDueTo": {
            "title": "Renewal due to (YYYY-MM-DD)",
            "type": "string",
            "description": "Optional end of a renewal-date range."
          },
          "updatedSince": {
            "title": "Record updated since (YYYY-MM-DD)",
            "type": "string",
            "description": "Only records whose LEI data was updated on or after this date."
          },
          "registrationStatuses": {
            "title": "LEI registration statuses",
            "type": "array",
            "description": "Any of <code>ISSUED</code>, <code>LAPSED</code>, <code>PENDING_TRANSFER</code>, <code>PENDING_ARCHIVAL</code>, <code>RETIRED</code>, <code>ANNULLED</code>, <code>DUPLICATE</code>, <code>MERGED</code>, <code>TRANSFERRED</code>.",
            "items": {
              "type": "string"
            }
          },
          "entityStatus": {
            "title": "Entity status",
            "enum": [
              "",
              "ACTIVE",
              "INACTIVE"
            ],
            "type": "string",
            "description": "Whether the legal entity itself is active.",
            "default": ""
          },
          "category": {
            "title": "Entity category",
            "enum": [
              "",
              "GENERAL",
              "BRANCH",
              "FUND",
              "RESIDENT_GOVERNMENT_ENTITY",
              "INTERNATIONAL_ORGANIZATION"
            ],
            "type": "string",
            "description": "Sole proprietors (individuals) and trusts are never returned.",
            "default": ""
          },
          "legalFormCodes": {
            "title": "Legal form codes (ISO 20275)",
            "type": "array",
            "description": "Entity legal form codes, e.g. <code>H0PO</code> (UK private limited company).",
            "items": {
              "type": "string"
            }
          },
          "registeredAs": {
            "title": "Registered number",
            "type": "string",
            "description": "The entity's number in its business register, e.g. a Companies House number."
          },
          "parentLei": {
            "title": "Parent LEI",
            "type": "string",
            "description": "For <b>Subsidiaries</b>: the parent's LEI."
          },
          "childLevel": {
            "title": "Children",
            "enum": [
              "direct",
              "ultimate"
            ],
            "type": "string",
            "description": "Direct children report this LEI as their direct parent; ultimate children report it as their ultimate parent.",
            "default": "direct"
          },
          "includeParents": {
            "title": "Add direct and ultimate parents",
            "type": "boolean",
            "description": "Adds the direct and ultimate parent LEI and name (or the reason no parent is reported). Uses 2 to 4 extra API requests per record, so large searches run slower.",
            "default": true
          },
          "includeLegalFormNames": {
            "title": "Add legal form names",
            "type": "boolean",
            "description": "Adds the English name of each legal form code (one cached request per code).",
            "default": true
          },
          "maxResults": {
            "title": "Max records",
            "minimum": 0,
            "type": "integer",
            "description": "Stop after this many records. 0 means no limit. You are charged per record returned.",
            "default": 25
          },
          "monitorMode": {
            "title": "Monitor mode (only new or updated records)",
            "type": "boolean",
            "description": "Remember each record's last update and, on later runs, return only records that are new or were updated since. Schedule the Actor to watch LEIs for lapses, renewals, name changes or new parents.",
            "default": false
          },
          "emitBaselineOnFirstRun": {
            "title": "Return records on the first monitor run",
            "type": "boolean",
            "description": "Off: the first monitor run only records what exists (no rows, no charges).",
            "default": true
          },
          "stateStoreName": {
            "title": "Monitor state store name",
            "type": "string",
            "description": "Named key-value store for monitor state. Use a different name per watch list.",
            "default": "lei-company-monitor"
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}