> ## Documentation Index
> Fetch the complete documentation index at: https://docs.openregister.de/llms.txt
> Use this file to discover all available pages before exploring further.

# Advanced company search

## Search companies

Perform advanced searches with complex filters to find companies matching specific criteria. Combine multiple filters on company attributes, financial metrics, ownership characteristics, and geographic location to identify your exact target audience.

**Cost:** 10 credits per search

### Powerful Filtering Options

Use filters to search by company status, legal form, location (city, postal code, or radius), industry codes, financial metrics (revenue, employees, balance sheet), incorporation date, ownership structure (family-owned, sole owner, owner-managed), insolvency status (`had_insolvency`, `has_open_insolvency`, `insolvency_stage`, `insolvency_opened_at`), and more. Combine multiple filters with AND logic to narrow your results precisely.

You can filter by over 70 different fields, including more than 45 financial indicators such as balance sheet totals, employee counts, provisions, and receivables, plus youngest owner age, capital amounts, and specific ownership characteristics. See our [filtering guide](/filtering) for detailed examples and all available filter fields.

### Use Cases

**Lead Generation:** Find companies matching your ideal customer profile. For example, search for GmbH companies in a specific industry with 50-200 employees and revenue over €5M in your target region.

**Market Analysis:** Identify all companies in a specific industry sector, analyze their distribution across regions, or find newly incorporated businesses in your market.

**Succession Planning:** Search for owner-managed companies where the owner is approaching retirement age (`youngest_owner_age > 60`, `has_representative_owner = true`) - perfect for identifying acquisition opportunities or succession planning services.

A full list of all German register courts is available [here](https://drive.google.com/file/d/1TkLE8myGlbj65Kub25mTxTbxiKJJ_zzE/view?usp=sharing).


## OpenAPI

````yaml POST /v1/search/company
openapi: 3.1.0
info:
  title: OpenRegister API
  version: 2.5.0
  description: >
    API for accessing comprehensive company data from official registers.

    This API provides access to company information, shareholder data, financial
    reports, and contact details.
servers:
  - url: https://api.openregister.de
    description: Production
security:
  - BearerAuth: []
paths:
  /v1/search/company:
    post:
      tags:
        - v1
      summary: Search for companies
      operationId: companyFilterSearch
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CompanySearchRequest'
        required: true
      responses:
        '200':
          description: Successful search operation
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/CompanySearchResponse'
        '400':
          description: Bad Request - Invalid parameters provided
        '401':
          description: Unauthorized - Authentication required
        '402':
          description: Payment Required - Insufficient credits for this request
        '429':
          description: Too Many Requests - Rate limit exceeded
        '500':
          description: >-
            Internal Server Error - An error occurred while processing the
            request
      x-codeSamples:
        - lang: JavaScript
          source: |-
            import Openregister from 'openregister';

            const client = new Openregister({
              apiKey: process.env['OPENREGISTER_API_KEY'], // This is the default and can be omitted
            });

            const companySearch = await client.search.findCompaniesV1();

            console.log(companySearch.pagination);
        - lang: Python
          source: |-
            import os
            from openregister import Openregister

            client = Openregister(
                api_key=os.environ.get("OPENREGISTER_API_KEY"),  # This is the default and can be omitted
            )
            company_search = client.search.find_companies_v1()
            print(company_search.pagination)
        - lang: Go
          source: "package main\n\nimport (\n\t\"context\"\n\t\"fmt\"\n\n\t\"github.com/oregister/openregister-go\"\n\t\"github.com/oregister/openregister-go/option\"\n)\n\nfunc main() {\n\tclient := openregister.NewClient(\n\t\toption.WithAPIKey(\"My API Key\"),\n\t)\n\tcompanySearch, err := client.Search.FindCompaniesV1(context.TODO(), openregister.SearchFindCompaniesV1Params{})\n\tif err != nil {\n\t\tpanic(err.Error())\n\t}\n\tfmt.Printf(\"%+v\\n\", companySearch.Pagination)\n}\n"
        - lang: CLI
          source: |-
            openregister search find-companies-v1 \
              --api-key 'My API Key'
components:
  schemas:
    CompanySearchRequest:
      type: object
      properties:
        query:
          $ref: '#/components/schemas/CompanySearchRequestQuery'
          description: |
            Search query to filter companies.
        filters:
          description: |
            Filters to filter companies.
          type: array
          items:
            $ref: '#/components/schemas/CompanySearchFilter'
        location:
          $ref: '#/components/schemas/CompanySearchLocationFilter'
          description: |
            Location to filter companies.
        pagination:
          $ref: '#/components/schemas/SearchRequestPagination'
          description: |
            Pagination parameters.
    CompanySearchResponse:
      type: object
      properties:
        results:
          type: array
          description: |
            List of companies matching the search criteria.
          items:
            $ref: '#/components/schemas/CompanySearchResponseItem'
        pagination:
          $ref: '#/components/schemas/Pagination'
      required:
        - results
        - pagination
    CompanySearchRequestQuery:
      type: object
      properties:
        value:
          type: string
          description: |
            Search query to filter companies.
      required:
        - value
    CompanySearchFilter:
      allOf:
        - $ref: '#/components/schemas/SearchFilterBase'
        - type: object
          properties:
            field:
              $ref: '#/components/schemas/CompanySearchFilterField'
          required:
            - field
    CompanySearchLocationFilter:
      type: object
      properties:
        longitude:
          type: number
          x-go-type: float64
          description: |
            Longitude to filter on.
        latitude:
          type: number
          x-go-type: float64
          description: |
            Latitude to filter on.
        radius:
          type: number
          description: |
            Radius in kilometers to filter on.
            Example: 10
      required:
        - longitude
        - latitude
    SearchRequestPagination:
      type: object
      properties:
        page:
          type: integer
          description: |
            Page number to return.
        per_page:
          type: integer
          description: |
            Number of results per page.
    CompanySearchResponseItem:
      type: object
      properties:
        company_id:
          type: string
          description: |
            Unique company identifier.
            Example: DE-HRB-F1103-267645
        name:
          type: string
          description: |
            Official registered company name.
            Example: "Max Mustermann GmbH"
        country:
          type: string
          description: >
            Country where the company is registered using ISO 3166-1 alpha-2
            code.

            Example: "DE" for Germany
          nullable: true
        register_number:
          type: string
          description: |
            Registration number in the company register.
            Example: "230633"
        register_type:
          $ref: '#/components/schemas/CompanyRegisterType'
          description: |
            Type of company register.
            Example: "HRB" for Commercial Register B
        register_court:
          type: string
          description: |
            Court where the company is registered.
            Example: "Berlin (Charlottenburg)"
        active:
          type: boolean
          description: |
            Company status - true if active, false if inactive.
        legal_form:
          $ref: '#/components/schemas/CompanyLegalForm'
          description: |
            Legal form of the company.
            Example: "gmbh" for Gesellschaft mit beschränkter Haftung
        address:
          description: >
            Current registered address of the company, taken from the search
            index.
          nullable: true
          allOf:
            - $ref: '#/components/schemas/CompanySearchAddress'
        purpose:
          type: string
          description: >
            Current official business purpose of the company, taken from the
            search index.
          nullable: true
      required:
        - company_id
        - name
        - country
        - register_number
        - register_type
        - register_court
        - active
        - legal_form
        - address
        - purpose
    Pagination:
      type: object
      properties:
        page:
          type: integer
          description: Current page number.
        per_page:
          type: integer
          description: Number of results per page.
        total_pages:
          type: integer
          description: Total number of pages.
        total_results:
          type: integer
          description: Total number of results.
      required:
        - page
        - per_page
        - total_pages
        - total_results
    SearchFilterBase:
      type: object
      description: >
        Filter by field. The property sets `value`, `values`, `keywords` and
        `min`/`max`

        are mutually exclusive. Dates must be YYYY-MM-DD.
      properties:
        value:
          type: string
        min:
          type: string
        max:
          type: string
        values:
          type: array
          items:
            type: string
        keywords:
          type: array
          items:
            type: string
    CompanySearchFilterField:
      type: string
      enum:
        - status
        - legal_form
        - register_number
        - register_court
        - register_type
        - city
        - active
        - incorporated_at
        - zip
        - address
        - balance_sheet_total
        - revenue
        - cash
        - employees
        - equity
        - real_estate
        - materials
        - pension_provisions
        - salaries
        - taxes
        - other_taxes
        - commission_income
        - commission_expense
        - liabilities
        - capital_reserves
        - active_accruals
        - passive_accruals
        - fixed_assets
        - current_assets
        - receivables
        - trade_receivables
        - inventory
        - provisions
        - bank_debt
        - trade_payables
        - tangible_assets
        - financial_assets
        - retained_earnings
        - profit_carryforward
        - other_provisions
        - shareholder_liabilities
        - operating_depreciation
        - financial_depreciation
        - other_operating_income
        - interest_income
        - interest_expense
        - other_liabilities
        - financial_debt
        - intangible_assets
        - other_operating_expenses
        - affiliated_liabilities
        - net_income
        - parent_net_income
        - income_before_tax
        - income_after_tax
        - ebit
        - ebitda
        - industry_codes
        - capital_amount
        - capital_currency
        - number_of_owners
        - has_sole_owner
        - has_representative_owner
        - is_family_owned
        - youngest_owner_age
        - purpose
        - has_lei
        - lei
        - had_insolvency
        - has_open_insolvency
        - insolvency_stage
        - insolvency_opened_at
    CompanyRegisterType:
      type: string
      description: >
        Type of company register where the entity is recorded.

        Common types:

        - HRB: Commercial Register B (limited liability companies, stock
        corporations)

        - HRA: Commercial Register A (partnerships, sole proprietorships)

        - PR: Partnership Register

        - GnR: Cooperative Register

        - VR: Association Register
      enum:
        - HRB
        - HRA
        - PR
        - GnR
        - VR
    CompanyLegalForm:
      type: string
      description: >
        Legal form of the company.

        Common German legal forms:

        - gmbh: Gesellschaft mit beschränkter Haftung (Limited Liability
        Company)

        - ag: Aktiengesellschaft (Stock Corporation)

        - ug: Unternehmergesellschaft (Entrepreneurial Company with limited
        liability)

        - ohg: Offene Handelsgesellschaft (General Partnership)

        - kg: Kommanditgesellschaft (Limited Partnership)

        - ev: Eingetragener Verein (Registered Association)
      enum:
        - ag
        - eg
        - ek
        - ev
        - ewiv
        - foreign
        - gbr
        - ggmbh
        - gmbh
        - kg
        - kgaa
        - unknown
        - llp
        - municipal
        - ohg
        - se
        - ug
    CompanySearchAddress:
      type: object
      properties:
        street:
          description: |
            Street name and number.
            Example: "Musterstraße 1"
          type: string
        city:
          description: |
            City or locality name.
            Example: "Berlin"
          type: string
        postal_code:
          description: |
            Postal or ZIP code.
            Example: "10117"
          type: string
        country:
          description: |
            Country of the address using ISO 3166-1 alpha-2 code.
            Example: "DE" for Germany
          type: string
        extra:
          description: |
            Additional address information such as c/o or attention line.
            Example: "c/o Max Mustermann"
          type: string
        formatted_value:
          description: |
            Complete address formatted as a single string.
            Example: "Musterstraße 1, 10117 Berlin"
          type: string
      required:
        - city
        - country
        - formatted_value
  securitySchemes:
    BearerAuth:
      type: http
      scheme: bearer
      description: |
        API Key Authentication
        Provide your API key as a Bearer token in the Authorization header.

````