> For the complete documentation index, see [llms.txt](https://manual.personr.co/api-documentation/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://manual.personr.co/api-documentation/entities/search-for-a-company.md).

# Search for a company

Before creating an Entity, you can perform a lookup search to fill more details for a more accurate check

## Company Search

<mark style="color:green;">`POST`</mark> `/api-company-search`

Perform a registry search if you only have either a Company's Name or Registration Number, to retrieve the missing information and/or confirm the details match what is present on the relevant registry.

{% hint style="warning" %}
**Trusts and other ABN-only entities aren't searchable.** In Australia, company search covers companies registered with ASIC. Trusts, super funds and other entities that only have an ABN don't appear in the results. Create them directly with [Creating an entity](https://manual.personr.co/api-documentation/entities/creating-an-entity.md), using the 11-digit ABN as `registrationNumber`.
{% endhint %}

| Name          | Value                 |
| ------------- | --------------------- |
| Content-Type  | `multipart/form-data` |
| Authorization | `Bearer YOUR_TOKEN`   |

**Body**

<table><thead><tr><th>Name</th><th width="165">Type</th><th>Description</th></tr></thead><tbody><tr><td><code>companyName</code></td><td>string</td><td>The entity's legal name</td></tr><tr><td><code>registrationNumber</code></td><td>string</td><td>The entity's registration, or company number. e.g ACN/ABN for AUS. There's no separate <code>abn</code> parameter, so send an ABN here.</td></tr><tr><td><code>countryISO</code></td><td>string</td><td>The entity's country of incorporation (<a href="https://en.wikipedia.org/wiki/ISO_3166-1_alpha-3">ISO-3166 3 char</a>), e.g. <code>AUS</code> or <code>GBR</code>. <mark style="color:red;">(required).</mark></td></tr></tbody></table>

{% hint style="info" %}
**Sandbox workspaces.** Company search has no sandbox test data. In a sandbox workspace it searches the live registry, so sandbox test values (such as the test trust ABN) return no results.
{% endhint %}

#### Request

{% tabs %}
{% tab title="cURL" %}

```sh
curl --location 'https://enterprise.personr.co/api/1.1/wf/api-company-search' \
--header 'Authorization: Bearer YOUR_TOKEN' \
--form 'companyName="Acme Pty Ltd"' \
--form 'registrationNumber="123456789"' \
--form 'countryISO="AUS"'
```

{% endtab %}

{% tab title="Node.js" %}

```javascript
var axios = require('axios');
var FormData = require('form-data');
var data = new FormData();
data.append('companyName', 'Acme Pty Ltd');
data.append('registrationNumber', '123456789');
data.append('countryISO', 'AUS');

var config = {
  method: 'post',
maxBodyLength: Infinity,
  url: 'https://enterprise.personr.co/api/1.1/wf/api-company-search',
  headers: { 
    'Authorization': 'Bearer YOUR_TOKEN',
    ...data.getHeaders()
  },
  data : data
};

axios(config)
.then(function (response) {
  console.log(JSON.stringify(response.data));
})
.catch(function (error) {
  console.log(error);
});
```

{% endtab %}

{% tab title="Javascript" %}

```javascript
var form = new FormData();
form.append("companyName", "Acme Pty Ltd");
form.append("registrationNumber", "123456789");
form.append("countryISO", "AUS");

var settings = {
  "url": "https://enterprise.personr.co/api/1.1/wf/api-company-search",
  "method": "POST",
  "timeout": 0,
  "headers": {
    "Authorization": "Bearer YOUR_TOKEN"
  },
  "processData": false,
  "mimeType": "multipart/form-data",
  "contentType": false,
  "data": form
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
```

{% endtab %}

{% tab title="Ruby" %}

```ruby
require "uri"
require "net/http"

url = URI("https://enterprise.personr.co/api/1.1/wf/api-company-search")

https = Net::HTTP.new(url.host, url.port)
https.use_ssl = true

request = Net::HTTP::Post.new(url)
request["Authorization"] = "Bearer YOUR_TOKEN"
form_data = [['companyName', 'Acme Pty Ltd'],['registrationNumber', '123456789'],['countryISO', 'AUS']]
request.set_form form_data, 'multipart/form-data'
response = https.request(request)
puts response.read_body
```

{% endtab %}

{% tab title="Python" %}

```python
import requests

url = "https://enterprise.personr.co/api/1.1/wf/api-company-search"

payload={'companyName': 'Acme Pty Ltd',
'registrationNumber': '123456789',
'countryISO': 'AUS'
}

files=[

]
headers = {
  'Authorization': 'Bearer YOUR_TOKEN'
}

response = requests.request("POST", url, headers=headers, data=payload, files=files)

print(response.text)
```

{% endtab %}
{% endtabs %}

**Response**

{% tabs %}
{% tab title="200 (Australia)" %}

```json
{
    "status": "success",
    "results": [
        {
            "abn": "123456789",
            "acn": "123456789",
            "registeredName": "Acme Pty Ltd",
            "status": "Registered",
            "location": "VIC 3000",
            "entityType": "Australian Private Company",
            "tradingNames": [
                "ACME PTY LTD",
                "ACME MANUFACTURING PTY LTD"
            ]
        }
    ]
}
```

{% endtab %}

{% tab title="200 (other countries)" %}

```json
{
    "status": "success",
    "results": [
        {
            "name": "ACME",
            "registrationCode": "123456789",
            "countryCode": "FR"
        }
    ]
}
```

{% endtab %}

{% tab title="200 (no matches)" %}

```json
{
    "status": "success",
    "results": []
}
```

{% endtab %}
{% endtabs %}

{% hint style="info" %}
The top-level `status` tells you the search ran. Inside each Australian result, `status` is the company's registration status, for example `Registered` or `Deregistered`.
{% endhint %}


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://manual.personr.co/api-documentation/entities/search-for-a-company.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
