# MediaDataSet

## Performs the Get operation.

> Use this endpoint to execute the get workflow in MediaDataSetController.

```json
{"openapi":"3.0.1","info":{"title":"WebApi | v1","version":"1.0.0"},"tags":[{"name":"MediaDataSet"}],"servers":[{"url":"https://api.safegpt.nl/"}],"security":[{"Bearer":[]}],"components":{"securitySchemes":{"Bearer":{"type":"http","description":"JWT bearer token. Example: 'Bearer {token}'.","scheme":"bearer","bearerFormat":"JWT"}},"schemas":{"FilterDataViewModel":{"type":"object","properties":{"skip":{"type":"integer","description":"Number of records to skip from the start of the result set.","format":"int32","nullable":true},"take":{"type":"integer","description":"Maximum number of records to return.","format":"int32","nullable":true},"search":{"type":"string","description":"Free-text query applied to searchable fields.","nullable":true},"companyId":{"type":"string","description":"Company scope used to limit results to a specific tenant.","format":"uuid","nullable":true},"startDate":{"type":"string","description":"Inclusive start date for date-range filtering.","format":"date-time","nullable":true},"endDate":{"type":"string","description":"Inclusive end date for date-range filtering.","format":"date-time","nullable":true},"sorted":{"type":"array","items":{"$ref":"#/components/schemas/SortDescriptor"},"description":"Sorting instructions, ordered by priority.","nullable":true}},"description":"Represents a generic filter request for paged list endpoints."},"SortDescriptor":{"type":"object","properties":{"name":{"type":"string","description":"Gets or sets the Name."},"direction":{"type":"string","description":"Gets or sets the Direction."}},"description":"Represents the view model SortDescriptor."}}},"paths":{"/v1/MediaDataSet/Get/{vectorStoreId}":{"post":{"tags":["MediaDataSet"],"summary":"Performs the Get operation.","description":"Use this endpoint to execute the get workflow in MediaDataSetController.","parameters":[{"name":"vectorStoreId","in":"path","required":true,"schema":{"type":"string","format":"uuid"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/FilterDataViewModel"}},"text/json":{"schema":{"$ref":"#/components/schemas/FilterDataViewModel"}},"application/*+json":{"schema":{"$ref":"#/components/schemas/FilterDataViewModel"}}},"required":true},"responses":{"200":{"description":"OK"},"401":{"description":"Authentication is required."},"403":{"description":"The user is not authorized to access this endpoint."}}}}}}
```

## Performs the Get operation.

> Use this endpoint to execute the get workflow in MediaDataSetController.

```json
{"openapi":"3.0.1","info":{"title":"WebApi | v1","version":"1.0.0"},"tags":[{"name":"MediaDataSet"}],"servers":[{"url":"https://api.safegpt.nl/"}],"security":[{"Bearer":[]}],"components":{"securitySchemes":{"Bearer":{"type":"http","description":"JWT bearer token. Example: 'Bearer {token}'.","scheme":"bearer","bearerFormat":"JWT"}}},"paths":{"/v1/MediaDataSet/Get/{mediaDataSetId}":{"get":{"tags":["MediaDataSet"],"summary":"Performs the Get operation.","description":"Use this endpoint to execute the get workflow in MediaDataSetController.","parameters":[{"name":"mediaDataSetId","in":"path","required":true,"schema":{"type":"string","format":"uuid"}}],"responses":{"200":{"description":"OK"},"401":{"description":"Authentication is required."},"403":{"description":"The user is not authorized to access this endpoint."}}}}}}
```

## Create media data set.

> Use this endpoint to create media data set.\
> \
> Required roles: Admin, Knowledge Base Contributor, Moderator.

```json
{"openapi":"3.0.1","info":{"title":"WebApi | v1","version":"1.0.0"},"tags":[{"name":"MediaDataSet"}],"servers":[{"url":"https://api.safegpt.nl/"}],"security":[{"Bearer":[]}],"components":{"securitySchemes":{"Bearer":{"type":"http","description":"JWT bearer token. Example: 'Bearer {token}'.","scheme":"bearer","bearerFormat":"JWT"}},"schemas":{"CreateMediaDataSetViewModel":{"required":["vectorStoreId","name","sourceType"],"type":"object","properties":{"vectorStoreId":{"type":"string","description":"Identifier of the vector store that will own the new dataset.","format":"uuid"},"name":{"type":"string","description":"Dataset name shown in management screens."},"description":{"type":"string","description":"Optional dataset description.","nullable":true},"sourceType":{"$ref":"#/components/schemas/MediaDataSetSourceType"},"sourceReference":{"type":"string","description":"Optional external source reference, such as URL or identifier.","nullable":true},"autoSyncEnabled":{"type":"boolean","description":"Indicates whether automatic synchronization should start enabled."},"autoSyncSupported":{"type":"boolean","description":"Indicates whether auto-sync is supported for the selected source."}},"description":"Represents the payload for creating a media dataset within a vector store."},"MediaDataSetSourceType":{"type":"integer","description":"Source type for dataset synchronization and ingestion."}}},"paths":{"/v1/MediaDataSet/Create":{"post":{"tags":["MediaDataSet"],"summary":"Create media data set.","description":"Use this endpoint to create media data set.\n\nRequired roles: Admin, Knowledge Base Contributor, Moderator.","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateMediaDataSetViewModel"}},"text/json":{"schema":{"$ref":"#/components/schemas/CreateMediaDataSetViewModel"}},"application/*+json":{"schema":{"$ref":"#/components/schemas/CreateMediaDataSetViewModel"}}},"required":true},"responses":{"200":{"description":"OK"},"401":{"description":"Authentication is required."},"403":{"description":"The user is not authorized to access this endpoint."}}}}}}
```

## Update media data set.

> Use this endpoint to update media data set.\
> \
> Required roles: Admin, Knowledge Base Contributor, Moderator.

```json
{"openapi":"3.0.1","info":{"title":"WebApi | v1","version":"1.0.0"},"tags":[{"name":"MediaDataSet"}],"servers":[{"url":"https://api.safegpt.nl/"}],"security":[{"Bearer":[]}],"components":{"securitySchemes":{"Bearer":{"type":"http","description":"JWT bearer token. Example: 'Bearer {token}'.","scheme":"bearer","bearerFormat":"JWT"}},"schemas":{"UpdateMediaDataSetViewModel":{"type":"object","properties":{"name":{"type":"string","description":"Updated dataset name.","nullable":true},"description":{"type":"string","description":"Updated dataset description.","nullable":true},"sourceType":{"$ref":"#/components/schemas/NullableOfMediaDataSetSourceType"},"sourceReference":{"type":"string","description":"Updated external source reference.","nullable":true},"autoSyncEnabled":{"type":"boolean","description":"Updated flag that enables or disables automatic synchronization.","nullable":true},"autoSyncSupported":{"type":"boolean","description":"Updated flag indicating whether auto-sync is supported.","nullable":true}},"description":"Represents partial update fields for an existing media dataset."},"NullableOfMediaDataSetSourceType":{"type":"integer","description":"Updated source type used for ingestion and synchronization.","nullable":true}}},"paths":{"/v1/MediaDataSet/Update/{mediaDataSetId}":{"patch":{"tags":["MediaDataSet"],"summary":"Update media data set.","description":"Use this endpoint to update media data set.\n\nRequired roles: Admin, Knowledge Base Contributor, Moderator.","parameters":[{"name":"mediaDataSetId","in":"path","required":true,"schema":{"type":"string","format":"uuid"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateMediaDataSetViewModel"}},"text/json":{"schema":{"$ref":"#/components/schemas/UpdateMediaDataSetViewModel"}},"application/*+json":{"schema":{"$ref":"#/components/schemas/UpdateMediaDataSetViewModel"}}},"required":true},"responses":{"200":{"description":"OK"},"401":{"description":"Authentication is required."},"403":{"description":"The user is not authorized to access this endpoint."}}}}}}
```

## Delete media data set.

> Use this endpoint to delete media data set.\
> \
> Required roles: Admin, Knowledge Base Contributor, Moderator.

```json
{"openapi":"3.0.1","info":{"title":"WebApi | v1","version":"1.0.0"},"tags":[{"name":"MediaDataSet"}],"servers":[{"url":"https://api.safegpt.nl/"}],"security":[{"Bearer":[]}],"components":{"securitySchemes":{"Bearer":{"type":"http","description":"JWT bearer token. Example: 'Bearer {token}'.","scheme":"bearer","bearerFormat":"JWT"}}},"paths":{"/v1/MediaDataSet/Delete/{mediaDataSetId}":{"delete":{"tags":["MediaDataSet"],"summary":"Delete media data set.","description":"Use this endpoint to delete media data set.\n\nRequired roles: Admin, Knowledge Base Contributor, Moderator.","parameters":[{"name":"mediaDataSetId","in":"path","required":true,"schema":{"type":"string","format":"uuid"}}],"responses":{"200":{"description":"OK"},"401":{"description":"Authentication is required."},"403":{"description":"The user is not authorized to access this endpoint."}}}}}}
```

## Adds media items to a dataset.

> Associates the selected media items with the target dataset, marks them active, and links them to the dataset vector store if needed.\
> \
> Required roles: Admin, Knowledge Base Contributor, Moderator.

```json
{"openapi":"3.0.1","info":{"title":"WebApi | v1","version":"1.0.0"},"tags":[{"name":"MediaDataSet"}],"servers":[{"url":"https://api.safegpt.nl/"}],"security":[{"Bearer":[]}],"components":{"securitySchemes":{"Bearer":{"type":"http","description":"JWT bearer token. Example: 'Bearer {token}'.","scheme":"bearer","bearerFormat":"JWT"}},"schemas":{"MediaDataSetMediaMutationViewModel":{"required":["mediaIds"],"type":"object","properties":{"mediaIds":{"type":"array","items":{"type":"string","format":"uuid"},"description":"Identifiers of media files to attach or detach."}},"description":"Represents a media selection used to add or remove media from a dataset."}}},"paths":{"/v1/MediaDataSet/AddMedia/{mediaDataSetId}":{"post":{"tags":["MediaDataSet"],"summary":"Adds media items to a dataset.","description":"Associates the selected media items with the target dataset, marks them active, and links them to the dataset vector store if needed.\n\nRequired roles: Admin, Knowledge Base Contributor, Moderator.","parameters":[{"name":"mediaDataSetId","in":"path","required":true,"schema":{"type":"string","format":"uuid"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MediaDataSetMediaMutationViewModel"}},"text/json":{"schema":{"$ref":"#/components/schemas/MediaDataSetMediaMutationViewModel"}},"application/*+json":{"schema":{"$ref":"#/components/schemas/MediaDataSetMediaMutationViewModel"}}},"required":true},"responses":{"200":{"description":"OK"},"401":{"description":"Authentication is required."},"403":{"description":"The user is not authorized to access this endpoint."}}}}}}
```

## Removes media items from a dataset.

> Clears dataset links for the selected media items when they currently belong to the specified dataset.\
> \
> Required roles: Admin, Knowledge Base Contributor, Moderator.

```json
{"openapi":"3.0.1","info":{"title":"WebApi | v1","version":"1.0.0"},"tags":[{"name":"MediaDataSet"}],"servers":[{"url":"https://api.safegpt.nl/"}],"security":[{"Bearer":[]}],"components":{"securitySchemes":{"Bearer":{"type":"http","description":"JWT bearer token. Example: 'Bearer {token}'.","scheme":"bearer","bearerFormat":"JWT"}},"schemas":{"MediaDataSetMediaMutationViewModel":{"required":["mediaIds"],"type":"object","properties":{"mediaIds":{"type":"array","items":{"type":"string","format":"uuid"},"description":"Identifiers of media files to attach or detach."}},"description":"Represents a media selection used to add or remove media from a dataset."}}},"paths":{"/v1/MediaDataSet/RemoveMedia/{mediaDataSetId}":{"post":{"tags":["MediaDataSet"],"summary":"Removes media items from a dataset.","description":"Clears dataset links for the selected media items when they currently belong to the specified dataset.\n\nRequired roles: Admin, Knowledge Base Contributor, Moderator.","parameters":[{"name":"mediaDataSetId","in":"path","required":true,"schema":{"type":"string","format":"uuid"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MediaDataSetMediaMutationViewModel"}},"text/json":{"schema":{"$ref":"#/components/schemas/MediaDataSetMediaMutationViewModel"}},"application/*+json":{"schema":{"$ref":"#/components/schemas/MediaDataSetMediaMutationViewModel"}}},"required":true},"responses":{"200":{"description":"OK"},"401":{"description":"Authentication is required."},"403":{"description":"The user is not authorized to access this endpoint."}}}}}}
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.safegpt.nl/api-nl/endpoints/mediadataset.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
