# API Introduction

The Deskpro API is a *REST* API that runs over HTTP(S). All API requests are made to a URL that begins with `http://example.com/api/v2/`.

The API uses *JSON* for requests and responses. There are a few exceptions to this rule where an API is explicitly designed to return a specific kind of resource. Those will be noted within the documentation.

Here’s an example call made to the `helpdesk/discover` endpoint:

```bash
curl http://example.com/api/v2/helpdesk/discover
```

The response will look something like this:

```javascript
{
    "data": {
        "is_deskpro": true,
        "helpdesk_url": "https:\/\/example.com\/",
        "base_api_url": "https:\/\/example.com\/api\/v2\/",
        "build": "1477995658"
    },
    "meta": {},
    "linked": {}
}
```


---

# Agent Instructions: Querying This Documentation

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

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://deskpro.gitbook.io/dev-guide/api-basics/api-introduction.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
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.
