# Examples of Neurelo Auto-Generated REST API endpoints

### Overview

Neurelo auto-generates a rich set of REST API endpoints from your schema for the project.

The API endpoints comprise of -

1. <mark style="color:green;">**GET**</mark> method endpoints to retrieve data
2. <mark style="color:blue;">**POST**</mark> method endpoints to add new data
3. <mark style="color:purple;">**PATCH**</mark> method endpoints to update data
4. <mark style="color:red;">**DELETE**</mark> method endpoints to delete data

{% hint style="info" %}
These endpoints support a rich set of filters, aggregation, sorting, pagination and other operations.
{% endhint %}

{% hint style="info" %}
These endpoints allow you to take action on a single object or across multiple objects in a single call, using any specified references between them (e.g. relationships, embedded documents).
{% endhint %}

The endpoints are reachable at **https\://$ENV\_API\_URL/rest/**

* **$ENV\_API\_URL** can be retrieved from the Neurelo environment in the project you want to use. This path will be different depending on the region where the runners for your environment have been instantiated.
* You will need an api key to use these endpoints.
  * API Keys can be generated within the settings of your Neurelo Environment.
  * An api key needs to be provided in the **X-API-KEY** header for your HTTPs calls and will look something like this

    ```json
    —header 'X-API-KEY: neurelo_9wAFBp854Z5xFw....q3S4++ktfGmelrcQI='
    ```
* You can download the **OpenAPI spec** for your auto-generated endpoints and a **Postman collection** to get you started from the API documentation page.

## Examples

The following pages cover examples for using the auto-generated REST APIs for 3 different sample schemas -&#x20;

1. [Example 1 - Simple "Posts" application](https://docs.neurelo.com/neurelo-api-reference-rest/examples-of-neurelo-auto-generated-rest-api-endpoints/example-1-simple-posts-application)
2. [Example 2 - "DVD Rentals" application](https://docs.neurelo.com/neurelo-api-reference-rest/examples-of-neurelo-auto-generated-rest-api-endpoints/example-2-dvd-rentals-application)
3. [Example 3 - "Bookstore" application](https://docs.neurelo.com/neurelo-api-reference-rest/examples-of-neurelo-auto-generated-rest-api-endpoints/example-3-bookstore-application)
4. [cURL examples for using the APIs](https://docs.neurelo.com/neurelo-api-reference-rest/examples-of-neurelo-auto-generated-rest-api-endpoints/curl-api-examples)
