Support
FAQS
Frequently Asked Questions
How do I make a call to the REST API?
To make a call to the REST API, you’ll need to use an HTTP client. First, set the request method (GET, POST, etc.), include your API key for authentication in the header, and specify the endpoint URL. For example, to retrieve property listings, you might use a GET request to https://api.yoursite.com/listings
. Ensure to handle the response to process the data returned from the API.
What authentication method is required for accessing the API?
Our API requires API key authentication. Include your API key in the request header as follows: Authorization: Bearer YOUR_API_KEY
. This ensures that your requests are secure and authenticated.
How can I handle pagination in API responses?
Pagination is handled using query parameters in the API request. You can specify parameters like page
and limit
to control the number of results per page and the page number, respectively. For example, https://api.yoursite.com/listings?page=2&limit=20
retrieves the second page of listings with 20 listings per page.
Can I filter the data retrieved from the API?
Yes, our API supports filtering the data. You can include specific query parameters in your request URL to filter results based on criteria such as location, price range, and property type. For example, to find properties under $500,000 in Toronto, you might use: https://api.yoursite.com/listings?city=Toronto&max_price=500000
.
How do I update data using the API?
To update data, use the PUT or PATCH method. Include the API endpoint that corresponds to the data you wish to update, and provide the new data in the request body. For instance, to update a listing, you might send a PUT request to https://api.yoursite.com/listings/123
with the updated property details in the body.
What should I do if I encounter an error with the API?
If you encounter an error, first check the status code and the error message provided in the response. This information can often indicate what went wrong (e.g., 404 Not Found
, 401 Unauthorized
). Consult our detailed documentation for guidance on error codes, or contact our support team for assistance with troubleshooting. Always ensure that your API key is valid and that you are using the correct endpoint and parameters.