> For the complete documentation index, see [llms.txt](https://docs.openalgo.in/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.openalgo.in/api-documentation/v1/accounts-api/ping.md).

# Ping

### Endpoint URL

This API Function checks connectivity and validates the API key authentication with the OpenAlgo platform

```http
Local Host   :  POST http://127.0.0.1:5000/api/v1/ping
Ngrok Domain :  POST https://<your-ngrok-domain>.ngrok-free.app/api/v1/ping
Custom Domain:  POST https://<your-custom-domain>/api/v1/ping
```

### Sample API Request

```json
{ 
"apikey": "<your_app_apikey>" 
}
```

### Sample API Response

```json
{
  "data": {
    "broker": "upstox",
    "message": "pong"
  },
  "status": "success"
}
```

### Request Body

| Parameters | Description | Mandatory/Optional | Default Value |
| ---------- | ----------- | ------------------ | ------------- |
| apikey     | App API key | Mandatory          | -             |

### Response Fields

| Field   | Type   | Description                                        |
| ------- | ------ | -------------------------------------------------- |
| status  | string | Status of the request (success/error)              |
| message | string | Response message ("pong" on successful connection) |
| broker  | string | Name of the connected broker                       |

### Error Response

```json
{ 
"status": "error", "message": "Invalid openalgo apikey" 
}
```

Notes

1. Use this endpoint to verify API connectivity before making other API calls
2. Validates that the API key is correctly configured and active
3. Returns the broker name associated with the validated API key
4. Rate limited to 10 requests per second (configurable via API\_RATE\_LIMIT)
5. Useful for health checks and monitoring API availability


---

# 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 dynamically by asking a question.

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

```
GET https://docs.openalgo.in/api-documentation/v1/accounts-api/ping.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
