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

# Lookup a Business

Find a business in a specific jurisdiction

You can lookup a business in authoritative registries for a given region by supplying either their name or the registration number relevant to the jurisdiction (eg: ACN in Australia).
This allows you to confirm that the organization exists, and we also fetch additional details such as their current legal status in supported regions.

The name need not be the full legal name; partial name search is supported by many regional registries.

Perform a business lookup with a partial name or number using the [/lookup](/api-reference/organizations/lookup-organizations) endpoint.

1. In the example below, replace `YOUR_CUSTOMER_ID` with your Customer ID and `YOUR_API_KEY` with your API key provided by FrankieOne.
2. Copy the resulting code into your command line, and run the command.

#### Request

<CodeGroup>
  ```bash Request - Name theme={null}
  curl --request POST \
      --url https://api.uat.frankie.one/v2/organizations/lookup \
      --header 'X-Frankie-CustomerId: YOUR_CUSTOMER_ID' \
      --header 'api_key: YOUR_API_KEY'
      --header 'content-type: application/json' \
      --data '{
          "organizationName": "FrankieOne",
          "region": {
              "country": "AUS"
          }
      }'
  ```

  ```bash Request - Number theme={null}
  curl --request POST \
      --url https://api.uat.frankie.one/v2/organizations/lookup \
      --header 'X-Frankie-CustomerId: YOUR_CUSTOMER_ID' \
      --header 'api_key: YOUR_API_KEY'
      --header 'content-type: application/json' \
      --data '{
          "organizationNumber": {
              "registrationNumber": "61623506892",
              "registryCode": "ABN"
          },
          "region": {
              "country": "AUS"
          }
      }'
  ```
</CodeGroup>

#### Response

The response will contain a list of businesses that matched against the lookup criteria supplied

<CodeGroup>
  ```json Response - Name theme={null}
  {
      "matchedOrganizations": [
          {
              "addresses": [
                  {
                      "country": "AUS",
                      "postalCode": "3000",
                      "subdivision": "VIC",
                      "type": "OFFICE_LOCALITY",
                      "unstructuredLongForm": "VIC 3000"
                  }
              ],
              "alternateNames": [
                  {
                      "name": "FRANKIE FINANCIAL PTY LTD",
                      "type": "Trading name"
                  },
                  {
                      "name": "FRANKIEONE",
                      "type": "Trading name"
                  }
              ],
              "country": "AUS",
              "name": {
                  "name": "FRANKIE FINANCIAL PTY LTD"
              },
              "organizationToken": "eyJ2ZXIiOiIxLjAiLCJ0cyI6IjIwMjUtMDktMTBUMDQ6Mzc6MDIuMDg3MDU3MzMzWiIsIm9uIjpbeyJybiI6IjYxNjIzNTA2ODkyIiwicmEiOiJBQk4ifSx7InJuIjoiNjIzNTA2ODkyIiwicmEiOiJBQ04ifV0sInByb3YiOiJjcmVkaXRvcndhdGNoIiwiY28iOiJBVVMifQ==",
              "registrationDetails": [
                  {
                      "registrationNumber": "61623506892",
                      "registrationNumberType": "ABN"
                  },
                  {
                      "registrationNumber": "623506892",
                      "registrationNumberType": "ACN"
                  }
              ],
              "status": {
                  "normalized": {
                      "code": "ACTV"
                  },
                  "unstructured": {
                      "description": "Registered"
                  }
              },
              "type": {
                  "code": "PRV",
                  "description": "Australian Private Company"
              }
          }
      ],
      "queryDetails": {
          "organizationName": "FrankieOne",
          "region": {
              "country": "AUS"
          }
      },
      "requestId": "01K4RYKAYFKYY7JJVEX234B0FN"
  }
  ```

  ```json Response - Number theme={null}
  {
      "matchedOrganizations": [
          {
              "addresses": [
                  {
                      "country": "AUS",
                      "postalCode": "3000",
                      "subdivision": "VIC",
                      "type": "OFFICE_LOCALITY",
                      "unstructuredLongForm": "VIC 3000"
                  }
              ],
              "alternateNames": [
                  {
                      "name": "FRANKIE FINANCIAL PTY LTD",
                      "type": "Trading name"
                  },
                  {
                      "name": "FRANKIEONE",
                      "type": "Trading name"
                  }
              ],
              "country": "AUS",
              "name": {
                  "name": "FRANKIE FINANCIAL PTY LTD"
              },
              "organizationToken": "eyJ2ZXIiOiIxLjAiLCJ0cyI6IjIwMjUtMDktMTBUMDQ6MzU6NDYuNTE0MTI2NzE0WiIsIm9uIjpbeyJybiI6IjYxNjIzNTA2ODkyIiwicmEiOiJBQk4ifSx7InJuIjoiNjIzNTA2ODkyIiwicmEiOiJBQ04ifV0sInByb3YiOiJjcmVkaXRvcndhdGNoIiwiY28iOiJBVVMifQ==",
              "registrationDetails": [
                  {
                      "registrationNumber": "61623506892",
                      "registrationNumberType": "ABN"
                  },
                  {
                      "registrationNumber": "623506892",
                      "registrationNumberType": "ACN"
                  }
              ],
              "status": {
                  "normalized": {
                      "code": "ACTV"
                  },
                  "unstructured": {
                      "description": "Registered"
                  }
              },
              "type": {
                  "code": "PRV",
                  "description": "Australian Private Company"
              }
          }
      ],
      "queryDetails": {
          "organizationNumber": {
              "registrationNumber": "61623506892",
              "registryCode": "ABN"
          },
          "region": {
              "country": "AUS"
          }
      },
      "requestId": "01K4RYH14PQYB7V5BD0MGAQWSS"
  }
  ```
</CodeGroup>

## Extract the organizationToken

<Check>
  ##### What's it used for?

  The organizationToken is used in subsequent steps to create an organization entity or to run a workflow.
</Check>

Lookup may return multiple matches. Each match will have some business details and a unique organizationToken. Be sure to extract the organizationToken matching the details of the organization you intend to process.

For example, extract the organizationToken for the first matched result:

```javascript Retrieving a Company code theme={null}
    const organizationToken = response["matchedOrganizations"][0]["organizationToken"];
```
