Here is how to connect and use REST API to MindsDB.
Here is an example in Python:
import requests # connect url = 'http://127.0.0.1:47334/api/sql/query' # query resp = requests.post(url, json={'query': 'SELECT * FROM example_db.demo_data.home_rentals LIMIT 10;'}) # response print(resp.text) # alternative: print(resp.json())
Was this page helpful?