> For the complete documentation index, see [llms.txt](https://docs.elentra.org/api/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.elentra.org/api/elentra-api-standards/routing-and-parameters/example-routing-patterns-with-http-method/courses-course-contacts-type-contact_type.md).

# /courses/{course}/contacts?type={contact\_type}

Collection/Resource/Sub-Collection?Query

{% tabs %}
{% tab title="GET" %}
Return a modified collection based on the query parameter's value.

{% hint style="info" %}
This will return all the contacts of the given course that are of contact type &#x58;*.*
{% endhint %}

{% hint style="warning" %}
On each newly added query parameter, evaluate if it should be structured as a sub-collection in the URI.
{% endhint %}
{% endtab %}

{% tab title="POST" %}
Query parameters are rarely used to modify the newly added resource or change the endpoint's behaviour.

{% hint style="danger" %}
Don't pass query parameters in `POST` requests. Pass data fields as `POST` parameters instead of query parameters.
{% endhint %}

{% hint style="warning" %}
This is very uncommon and usually not recommended.&#x20;
{% endhint %}
{% endtab %}

{% tab title="PUT" %}
Query parameters are rarely used to modify the newly added resource or change the endpoint's behaviour.

{% hint style="info" %}
It should be implied that this would replace the entire subset of contacts that match the query.
{% endhint %}

{% hint style="danger" %}
Don't pass query parameters in `PUT` requests. Pass data fields as `PUT` parameters instead of query parameters.
{% endhint %}

{% hint style="warning" %}
This is uncommon and not recommended.
{% endhint %}
{% endtab %}

{% tab title="PATCH" %}
Query parameters are used to modify the newly added resource or change the endpoint's behaviour.

This would imply modifying a subset of data matching the query.

{% hint style="info" %}
For example, reordering a large dataset of a course's contacts of a specific type (faster than looping PUT requests).
{% endhint %}

{% hint style="warning" %}
This is uncommon and not recommended because it's difficult to interpret what the endpoint is doing based on the URI alone.&#x20;
{% endhint %}
{% endtab %}

{% tab title="DELETE" %}
Deletes all entities that match the query parameter.

{% hint style="info" %}
For example, delete all the contacts of the given course that are of contact type &#x58;*.*
{% endhint %}

{% hint style="warning" %}
Use with care.
{% endhint %}
{% endtab %}
{% endtabs %}
