---
title: Accredited hospital search API
slug: api-marketplace/accredited-hospital-search-api
createdAt: 2024-06-06T08:56:59.313Z
---

## Introduction

This API is a part of Hospital/Healthcare accreditation verification API stack.&#x20;

The Hospital Accreditation Verification API provides detailed accreditation information for hospitals. By entering the name and address of a hospital, users can verify the accreditation status, including accreditation number, reference number, validity period, and current status. This API is essential for healthcare providers, insurance companies, and patients who need to ensure the credibility and quality of healthcare facilities.

The Accredited Hospital Search API returns the name and address of all hospitals that matches to the provided hospital name.

***

## API details

### Endpoint

:::CodeblockTabs
Production Environment

```jsx
POST https://api.signzy.app/api/v3/hospitals/search
```
:::

:::CodeblockTabs
Production Environment

```jsx
POST https://api-preproduction.signzy.app/api/v3/hospitals/search
```
:::

***

### Request headers&#x20;

| Name          | Value            | Required  | Description                                                                                                |
| ------------- | ---------------- | --------- | ---------------------------------------------------------------------------------------------------------- |
| Content-Type  | application/json | Mandatory | The type of content that the request body contains.                                                        |
| Authorization | XXXXXXXXXXXXXXX  | Mandatory | An authentication token to authorize the request. Reach out to the Signzy support team to get one created. |

### Request body parameters

| Parameter                | Data Type | Description | Required  |
| ------------------------ | --------- | ----------- | --------- |
| Hospital/Healthcare name | String    |             | Mandatory |
| address                  | String    |             | Optional  |

```json
{
    "name": "Shri Ram Singh Hospital & Heart",
    "address: "New Delhi"
}
```

***

### Code samples

:::CodeblockTabs
```curl
curl --location 'https://api-preproduction.signzy.app/api/v3/hospitals/search' \
--header 'Content-Type: application/json' \
--header 'authorization: <AUTH-TOKEN>' \
--data '{
        "name": "Shri Ram Singh Hospital",
        "address": "Delhi"
}'
```

```nodejs
const axios = require('axios');
let data = JSON.stringify({
  "name": "Shri Ram Singh Hospital",
  "address": "Delhi"
});

let config = {
  method: 'post',
  maxBodyLength: Infinity,
  url: 'https://api-preproduction.signzy.app/api/v3/hospitals/search',
  headers: { 
    'Content-Type': 'application/json', 
    'authorization': '<AUTHTOKEN>'
  },
  data : data
};

axios.request(config)
.then((response) => {
  console.log(JSON.stringify(response.data));
})
.catch((error) => {
  console.log(error);
});

```

```python
import requests
import json

url = "https://api-preproduction.signzy.app/api/v3/hospitals/search"

payload = json.dumps({
  "name": "Shri Ram Singh Hospital",
  "address": "Delhi"
})
headers = {
  'Content-Type': 'application/json',
  'authorization': '<AUTHTOKEN>'
}

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

print(response.text)

```

```go
package main

import (
  "fmt"
  "strings"
  "net/http"
  "io/ioutil"
)

func main() {

  url := "https://api-preproduction.signzy.app/api/v3/hospitals/search"
  method := "POST"

  payload := strings.NewReader(`{
        "name": "Shri Ram Singh Hospital",
        "address": "Delhi"
}`)

  client := &http.Client {
  }
  req, err := http.NewRequest(method, url, payload)

  if err != nil {
    fmt.Println(err)
    return
  }
  req.Header.Add("Content-Type", "application/json")
  req.Header.Add("authorization", "<AUTHTOKEN>")

  res, err := client.Do(req)
  if err != nil {
    fmt.Println(err)
    return
  }
  defer res.Body.Close()

  body, err := ioutil.ReadAll(res.Body)
  if err != nil {
    fmt.Println(err)
    return
  }
  fmt.Println(string(body))
}
```
:::

***

### Response body parameters

| Parameter      | Data Type | Description |
| -------------- | --------- | ----------- |
| result.name    | String    | Mandatory   |
| result.address | String    | Optional    |

:::CodeblockTabs
200

```json
{
    "result": [
        {
            "name": "Ahmedabad Institute Of Medical Services (AIMS)",
            "address": "ahmedabad gujarat"
        },
        {
            "name": "Sri Aurobindo Institute Of Medical Sciences (Saims Hospital)",
            "address": "indore madhya pradesh"
        },
        {
            "name": "Sri Aurobindo Institute Of Medical Sciences (SAIMS Hospital)",
            "address": "indore madhya pradesh"
        },
        {
            "name": "AIMS Hospital Unit of Shamaliya Enterprise",
            "address": "aravalli gujarat"
        },
        {
            "name": "AIMS for Child Health",
            "address": "vijayawada andhra pradesh"
        },
        {
            "name": "Sri Agastya Institute of Medical Sciences  (AIMS Hospital)",
            "address": "mancherial telangana"
        }
    ]
}
```

400

```json
//When the name is empty string
{
    "error": {
        "name": "error",
        "message": "Name is not allowed to be an empty string",
        "status": "Bad Request",
        "statusCode": 400
    }
}
//When the name is not a string
{
    "error": {
        "name": "error",
        "message": "Name must be a string",
        "status": "Bad Request",
        "statusCode": 400
    }
}
```

401

```json
// When API key is not passed in headers
{
    "message": "No API key found in request"
}

// When wrong API key is passed in headers
{
    "message": "Invalid authentication credentials"
}
```

404

```json
{
    "error": {
        "statusCode": "404",
        "name": "error",
        "message": "Not Found",
        "status": "404"
    }
}
```

409

```json
{
    "error": {
        "name": "error",
        "message": "Error in getting Data from Upstream",
        "status": 409,
        "reason": "ERROR",
        "type": "Conflict",
        "statusCode": 409
    }
}
```
:::

***

**Contact Us for Any Assistance**

If you have any questions or need assistance, please reach out to our customer support team. You can contact us via email at <font color="#2166ae">**help\@signzy.com**</font>. We strive to provide prompt and reliable assistance, ensuring your queries are addressed effectively.

We value your feedback and are committed to making your experience smooth and enjoyable. Our team is dedicated to assisting you with any needs you may have. Thank you for choosing our services. We look forward to helping you!

