List clinic plans by clinic slug
1 min
GET
https://developer.digitail.io/api/v1/public/clinics/{slug}/plans
Path Parameters
- slugstringrequiredDescription
Query Parameters
- includestringDescription
Responses
200
- object
- dataobject[]
- idintegerExample
- clinic_idintegerExample
- namestringExample
- descriptionstringExample
- pricenumberExample
- price_without_taxnumberExample
- taxnumberDescription
- tax_rates0[]Description
- upfront_feenumber
- upfront_fee_without_taxnumber
- periodicityintegerExample
- periodicity_typestring<day | week | month | quarter | year>Alloweddayweekmonthquarteryear
- plan_durationstring<indefinite | 1-year>DefaultindefiniteAllowedindefinite1-year
- benefitsbenefits
- linkslinks
- metameta
curl
curl --request GET \
--url https://developer.digitail.io/api/v1/public/clinics/{slug}/plans \
--header 'accept: application/json'javascript
var myHeaders = new Headers();
myHeaders.append("accept", "application/json");
myHeaders.append("content-type", "application/json");
var requestOptions = {
method: 'GET',
headers: myHeaders,
redirect: 'follow'
};
fetch("https://developer.digitail.io/api/v1/public/clinics/{slug}/plans", requestOptions)
.then(response => response.text())
.then(result => console.log(result))
.catch(error => console.log('error', error));ruby
require "uri"
require "json"
require "net/http"
url = URI("https://developer.digitail.io/api/v1/public/clinics/{slug}/plans")
https = Net::HTTP.new(url.host, url.port)
https.use_ssl = true
request = Net::HTTP::Get.new(url)
request["accept"] = "application/json"
request["content-type"] = "application/json"
response = https.request(request)
puts response.read_body
python
import requests
import json
url = "https://developer.digitail.io/api/v1/public/clinics/{slug}/plans"
payload = {}
headers = {
'accept': 'application/json',
'content-type': 'application/json'
}
response = requests.request("GET", url, headers=headers, data=payload)
print(response.text)
200
// successful operation
{
"data": [
{
"id": 1,
"clinic_id": 1,
"name": "Basic",
"description": "Basic subscription plan",
"price": 10,
"price_without_tax": 10,
"tax": 0,
"tax_rates": [
""
],
"upfront_fee": 0,
"upfront_fee_without_tax": 0,
"periodicity": 1,
"periodicity_type": "",
"plan_duration": "",
"benefits": {}
}
],
"links": {},
"meta": {}
}