> For the complete documentation index, see [llms.txt](https://docs.coresignal.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.coresignal.com/self-service/features-and-tools/api-playground.md).

# API Playground

Test Coresignal APIs with natural language prompts. Preview fresh data responses for company, employee, and jobs endpoints – no code needed.

Our **API Playground** offers a hands-on environment to learn how to search, collect, and look up relevant IDs using Coresignal's API. It’s designed to support onboarding, simplify integration, and help you test requests with minimal setup.

You can use the playground to:

* [Generate API queries](/guides/turning-a-natural-language-query-into-an-api-integration.md) using natural language input
* Write and edit [Elasticsearch](/api-introduction/requests/elasticsearch-dsl.md) query manually&#x20;
* View and adjust the full request structure
* [Collect](/guides/collect-enrich-or-bulk-collect.md) and preview sample responses one at a time
* Control visibility of data bundles
* Save search results as a List
* Copy ready-to-use Elasticsearch query for the request
* Get the [API key](/self-service/account-management/authentication-and-api-keys.md)

In the playground, you can also find sample prompts to help you get started. You can edit both the AI-generated query and the original prompt at any time including:

* Adding, removing, or updating filters
* Modifying record IDs
* Previewing different data records

## API playground environment

To start using the API playground, enter a natural-language prompt in the dedicated field. The tool then turns it into **Search** and **Collect** API queries, so you don’t need query-writing skills. It simplifies exploration and makes it easy to generate custom queries, helping you avoid errors.

Once a request is generated, the tool provides:

* The complete **search** and **collect** API requests
* The total number of matching records and their IDs in our database
* Initial sample record for a quick check with the option to view more records

In the **ELASTICSEARCH QUERY** section, you can see the generated query, which you can edit and copy. You can also select the entity that best suits your search intent, such as Employee, Company, or Jobs. The selection of the entity is mandatory.

<figure><img src="https://1300677093-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FAd1icWUeSjJeOMkIAMkM%2Fuploads%2FtSyH3LjYHlfxTYKltCDt%2FScreenshot%202026-10-19%20at%2014.22.32.png?alt=media&amp;token=3b8b61e4-28eb-4062-a9bc-3f6828d19dd8" alt=""><figcaption></figcaption></figure>

While the tool returns one sample record, to make sure the results match your query, you can copy a different ID from the records matched list or use the arrows on either side of the Record ID field in **Collect** to move to another record. Each ID record collection costs from 1 to 20 [credits](#credits), depending on the selected entity.

## Prompt information

For the best search results and to avoid errors, it is important to understand the prompting rules. Below, you can find useful tips, common errors, and how to fix them.

### Rules

Here are four main rules for successful prompting:

* Follow the structure of the prompt examples provided in the playground.
* Keep it short (**5-5,000 characters**) and refine your search through multiple prompts instead of overcomplicating a single prompt.
* Use precise criteria instead of broader adjectives. For example, instead of “biggest” or “top”, indicate a company size, revenue range, exact job role, required experience duration, etc.
* Aim to formulate prompts that resemble real data fields and values.

{% hint style="success" %}
The original prompt can be editable – refine and rerun as needed to fine-tune the results.
{% endhint %}

### Prompt and other errors

When using the API playground, you may encounter errors. Below is a detailed overview of four common error messages and how to resolve them.

#### Failed to submit the request

This error message appears when the system cannot process your query as written.

Here’s how you can try to adjust your prompt:

* **Remove requests for private data**. The most common reason for an error is an off-topic request. The AI cannot search for personal contact details, so you should remove any mention of emails or phone numbers from your prompt.
* **Ensure the prompt is well-formed**. A query can fail if it has a malformed or unsupported structure. The best way to fix this is to use one of the prompt examples as a guide to ensure your request is structured correctly.
* **Avoid using test inputs**. Prompts that consist of simple test inputs, typos, or random characters (e.g., “ddkdopqkwd”) are considered unsupported and will cause an error.
* **Make sure your prompt uses clear, descriptive language**. Vague or overly short requests can be misinterpreted, so describe exactly what you're looking for, including key details like industry, location, or role.

#### Insufficient credits

You’ll see this error message if you don’t have enough credits to generate or update a query. To submit a request, upgrade your plan and try again.

#### **Too many requests**

This error message appears after you reach the 10-request-per-hour limit. Once you get this message, try again later.

#### **No results**

If there are no results in our database, the post response field will display `0`. However, if the API playground fails to generate a data collection request, it returns an "Invalid query" message.

That doesn’t necessarily mean that we don’t have such data. Try to modify your prompt following the best practices:

* **Broaden your search criteria**. Too many or overly strict filters are a primary cause of empty results. Start with broader criteria, then narrow the search as needed.
* **Check for typos and spelling errors**. Requests often fail due to simple misspellings in the prompt. Ensure all names and terms are spelled correctly.
* **Verify that the entity exists**. The company or employee you are looking for may be rare, new, or not available in our dataset.

If you have followed the advice above and still get no results, the data you’re looking for likely isn't available in our database. Note that if the search returns 0 results, you are not charged any credits.

## Ways of submitting query

Coresignal’s API playground lets you submit your query by selecting a prompt from the examples list, manually, and resubmitting it:

* **Submitting a query from the prompt list**. You can select any of the available prompts from the prompt examples or use them as ideas to formulate your own prompt.
* **Submitting a query manually**. In the ELASTICSEARCH QUERY section, click start from scratch and write the DSL yourself.&#x20;
* **Re-submitting query**. If you are not fully satisfied with the search results, you can edit both your prompt and Elasticsearch query and resubmit it. This process costs 20 credits for employee and company data and 1 credit for jobs data.

## Credits

Generating and sending a request in the API Playground consumes credits. Each prompt, including generating a query, searching, and collecting, costs 1 credit for the multi-source Jobs record and 20 credits for the multi-source Company and Employee records. If you want to collect another ID from the return IDs list, it also costs additional credits. Find more information about credit usage on the [Pricing](https://docs.coresignal.com/pricing/) page.

## Data bundles

Company and employee data are organized into bundles. Each dataset includes a core bundle that is always collected, and you can add optional bundles: four for company data and three for employee data.

[Company data bundles](/company-data/bundles.md):

* Core company bundle&#x20;
* Financial information bundle
* Growth signals bundle
* Workforce intelligence bundle
* Company intelligence bundle

[Employee data bundles](/employee-data/bundles.md):

* Core employee bundle&#x20;
* Employer information bundle
* Career intelligence bundle
* Social influence bundle

Bundles are available after you enter the prompt and run it. For any other ID you collect after, you have an option to hide or show bundles.&#x20;

<img src="https://1300677093-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FAd1icWUeSjJeOMkIAMkM%2Fuploads%2FiIcFEUfPI3hwwEdyUqgM%2Funknown.png?alt=media&amp;token=b76f7173-d3b5-4949-b0cf-4a3a1cf94c16" alt="" height="339" width="553">

You can customize your Collect request by making the bundles visible or hiding them:

1. **Navigate** to the Collect section in the API
2. Hover over the bundle and click **Show** to add a bundle, or **Hide** to remove it.
3. Click a bundle to **expand** it and preview its fields. Click again to **collapse** it.

{% hint style="info" %}
Collect always costs 20 credits, regardless of how many bundles you add.
{% endhint %}

## Save as a List

Save any search from the API playground as a list so you can return to its results later without running the search again.

Open the **API playground**, type your prompt, then click **Generate & run**. After search results are returned, in the Search section, next to records matched, locate the **Save as a list** button – click it to save your search as a list. This action costs 20 credits.

<img src="https://1300677093-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FAd1icWUeSjJeOMkIAMkM%2Fuploads%2FKE7SWFNNvSrHQvVZGZwc%2Funknown.png?alt=media&amp;token=443d87d0-1d46-4c68-847e-8ed86f1e2cbb" alt="" height="202" width="594">

After you click **Save as a list**, a confirmation pop-up appears in the top-right corner of the window. You can see your list by clicking **Lists** in the pop-up.

<img src="https://1300677093-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FAd1icWUeSjJeOMkIAMkM%2Fuploads%2FbvKvkt926SvqgF0vnXKy%2Funknown.png?alt=media&amp;token=0d4ba3fe-3b97-4cb7-97ec-597462e26923" alt="" height="92" width="357">


---

# 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://docs.coresignal.com/self-service/features-and-tools/api-playground.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.
