# Playbook Source Documents

## Gets playbook source documents by container.

> Retrieves playbook source documents for a container with optional filtering and pagination.

```json
{"openapi":"3.0.4","info":{"title":"Playbook Marketplace API","version":"v1"},"servers":[{"url":"https://api.{tenant}.{region}.jylo.ai","variables":{"tenant":{"default":"example","description":"Tenant name"},"region":{"default":"uk","description":"Region","enum":["uk","us","eu","au","jp"]}}}],"security":[{"Bearer":[]}],"components":{"securitySchemes":{"Bearer":{"type":"http","description":"Bearer authentication with JWT","scheme":"bearer","bearerFormat":"JWT"}},"schemas":{"Jylo.Toolkit.Sorting.ItemSorting":{"enum":[0],"type":"integer","format":"int32"},"PaginationListModel.DocumentReadModel":{"type":"object","properties":{"items":{"type":"array","items":{"$ref":"#/components/schemas/Jylo.Toolkit.API.Models.Documents.DocumentReadModel"},"nullable":true},"totalCount":{"type":"integer","format":"int32"}},"additionalProperties":false},"Jylo.Toolkit.API.Models.Documents.DocumentReadModel":{"required":["documentUploadObjectIdentifier","name"],"type":"object","properties":{"name":{"type":"string","nullable":true},"parentObjectIdentifier":{"type":"string","format":"uuid","nullable":true},"isDirectory":{"type":"boolean"},"documentUploadObjectIdentifier":{"type":"string","format":"uuid"},"contentType":{"type":"string","nullable":true},"size":{"type":"integer","format":"int64","nullable":true},"objectIdentifier":{"type":"string","format":"uuid"},"dateAdded":{"type":"string","format":"date-time"},"uploadSuccessful":{"type":"boolean","nullable":true},"tokenCount":{"type":"integer","format":"int64","nullable":true},"metadataTokenCount":{"type":"integer","format":"int64","nullable":true},"unsupportedFileType":{"type":"boolean","nullable":true},"unPackingComplete":{"type":"boolean","nullable":true},"unPackingFailed":{"type":"boolean","nullable":true},"uploadInProgress":{"type":"boolean","nullable":true},"url":{"type":"string","nullable":true},"hasChildren":{"type":"boolean","nullable":true},"resourceOwner":{"$ref":"#/components/schemas/Jylo.Toolkit.API.Models.OrganizationMemberModel"}},"additionalProperties":false},"Jylo.Toolkit.API.Models.OrganizationMemberModel":{"required":["id","name"],"type":"object","properties":{"email":{"type":"string","nullable":true},"name":{"type":"string","nullable":true},"id":{"type":"string","nullable":true}},"additionalProperties":false},"Microsoft.AspNetCore.Mvc.ProblemDetails":{"type":"object","properties":{"type":{"type":"string","nullable":true},"title":{"type":"string","nullable":true},"status":{"type":"integer","format":"int32","nullable":true},"detail":{"type":"string","nullable":true},"instance":{"type":"string","nullable":true}},"additionalProperties":{}}}},"paths":{"/playbooks/{playbookIdentifier}/source-documents":{"get":{"tags":["Playbook Source Documents"],"summary":"Gets playbook source documents by container.","description":"Retrieves playbook source documents for a container with optional filtering and pagination.","parameters":[{"name":"pageNumber","in":"query","description":"The page number for pagination.","schema":{"type":"integer","format":"int32"}},{"name":"parentObjectIdentifier","in":"query","description":"The optional parent object identifier.","schema":{"type":"string","format":"uuid"}},{"name":"flattenList","in":"query","description":"Whether to flatten the list.","schema":{"type":"boolean"}},{"name":"pageSize","in":"query","description":"The page size for pagination.","schema":{"type":"integer","format":"int32"}},{"name":"searchText","in":"query","description":"The search text to filter documents.","schema":{"type":"string"}},{"name":"sorting","in":"query","description":"The sorting option.","schema":{"$ref":"#/components/schemas/Jylo.Toolkit.Sorting.ItemSorting"}},{"name":"desc","in":"query","description":"Whether to sort in descending order.","schema":{"type":"boolean","default":true}},{"name":"playbookIdentifier","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"text/plain":{"schema":{"$ref":"#/components/schemas/PaginationListModel.DocumentReadModel"}},"application/json":{"schema":{"$ref":"#/components/schemas/PaginationListModel.DocumentReadModel"}},"text/json":{"schema":{"$ref":"#/components/schemas/PaginationListModel.DocumentReadModel"}}}},"400":{"description":"Bad Request","content":{"text/plain":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}},"application/json":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}},"text/json":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}}}},"403":{"description":"Forbidden","content":{"text/plain":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}},"application/json":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}},"text/json":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}}}}}}}}}
```

## Creates a new playbook source document.

> Creates a new playbook source document by uploading a file.

```json
{"openapi":"3.0.4","info":{"title":"Playbook Marketplace API","version":"v1"},"servers":[{"url":"https://api.{tenant}.{region}.jylo.ai","variables":{"tenant":{"default":"example","description":"Tenant name"},"region":{"default":"uk","description":"Region","enum":["uk","us","eu","au","jp"]}}}],"security":[{"Bearer":[]}],"components":{"securitySchemes":{"Bearer":{"type":"http","description":"Bearer authentication with JWT","scheme":"bearer","bearerFormat":"JWT"}},"schemas":{"Jylo.Toolkit.API.Models.Documents.DocumentReadModel":{"required":["documentUploadObjectIdentifier","name"],"type":"object","properties":{"name":{"type":"string","nullable":true},"parentObjectIdentifier":{"type":"string","format":"uuid","nullable":true},"isDirectory":{"type":"boolean"},"documentUploadObjectIdentifier":{"type":"string","format":"uuid"},"contentType":{"type":"string","nullable":true},"size":{"type":"integer","format":"int64","nullable":true},"objectIdentifier":{"type":"string","format":"uuid"},"dateAdded":{"type":"string","format":"date-time"},"uploadSuccessful":{"type":"boolean","nullable":true},"tokenCount":{"type":"integer","format":"int64","nullable":true},"metadataTokenCount":{"type":"integer","format":"int64","nullable":true},"unsupportedFileType":{"type":"boolean","nullable":true},"unPackingComplete":{"type":"boolean","nullable":true},"unPackingFailed":{"type":"boolean","nullable":true},"uploadInProgress":{"type":"boolean","nullable":true},"url":{"type":"string","nullable":true},"hasChildren":{"type":"boolean","nullable":true},"resourceOwner":{"$ref":"#/components/schemas/Jylo.Toolkit.API.Models.OrganizationMemberModel"}},"additionalProperties":false},"Jylo.Toolkit.API.Models.OrganizationMemberModel":{"required":["id","name"],"type":"object","properties":{"email":{"type":"string","nullable":true},"name":{"type":"string","nullable":true},"id":{"type":"string","nullable":true}},"additionalProperties":false},"Microsoft.AspNetCore.Mvc.ProblemDetails":{"type":"object","properties":{"type":{"type":"string","nullable":true},"title":{"type":"string","nullable":true},"status":{"type":"integer","format":"int32","nullable":true},"detail":{"type":"string","nullable":true},"instance":{"type":"string","nullable":true}},"additionalProperties":{}}}},"paths":{"/playbooks/{playbookIdentifier}/source-documents":{"post":{"tags":["Playbook Source Documents"],"summary":"Creates a new playbook source document.","description":"Creates a new playbook source document by uploading a file.","parameters":[{"name":"parentObjectIdentifier","in":"query","description":"The optional parent object identifier.","schema":{"type":"string","format":"uuid"}},{"name":"documentUploadIdentifier","in":"query","description":"The unique identifier for the document upload.","required":true,"schema":{"type":"string","format":"uuid"}},{"name":"playbookIdentifier","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"content":{"multipart/form-data":{"schema":{"type":"object","properties":{"file":{"type":"string","description":"The file to upload.","format":"binary"}}},"encoding":{"file":{"style":"form"}}}}},"responses":{"201":{"description":"Created","content":{"text/plain":{"schema":{"$ref":"#/components/schemas/Jylo.Toolkit.API.Models.Documents.DocumentReadModel"}},"application/json":{"schema":{"$ref":"#/components/schemas/Jylo.Toolkit.API.Models.Documents.DocumentReadModel"}},"text/json":{"schema":{"$ref":"#/components/schemas/Jylo.Toolkit.API.Models.Documents.DocumentReadModel"}}}},"400":{"description":"Bad Request","content":{"text/plain":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}},"application/json":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}},"text/json":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}}}},"403":{"description":"Forbidden","content":{"text/plain":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}},"application/json":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}},"text/json":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}}}}}}}}}
```

## Creates an empty playbook source document.

> Creates an empty playbook source document with specified file name and content type.

```json
{"openapi":"3.0.4","info":{"title":"Playbook Marketplace API","version":"v1"},"servers":[{"url":"https://api.{tenant}.{region}.jylo.ai","variables":{"tenant":{"default":"example","description":"Tenant name"},"region":{"default":"uk","description":"Region","enum":["uk","us","eu","au","jp"]}}}],"security":[{"Bearer":[]}],"components":{"securitySchemes":{"Bearer":{"type":"http","description":"Bearer authentication with JWT","scheme":"bearer","bearerFormat":"JWT"}},"schemas":{"Jylo.Toolkit.API.Models.Documents.DocumentReadModel":{"required":["documentUploadObjectIdentifier","name"],"type":"object","properties":{"name":{"type":"string","nullable":true},"parentObjectIdentifier":{"type":"string","format":"uuid","nullable":true},"isDirectory":{"type":"boolean"},"documentUploadObjectIdentifier":{"type":"string","format":"uuid"},"contentType":{"type":"string","nullable":true},"size":{"type":"integer","format":"int64","nullable":true},"objectIdentifier":{"type":"string","format":"uuid"},"dateAdded":{"type":"string","format":"date-time"},"uploadSuccessful":{"type":"boolean","nullable":true},"tokenCount":{"type":"integer","format":"int64","nullable":true},"metadataTokenCount":{"type":"integer","format":"int64","nullable":true},"unsupportedFileType":{"type":"boolean","nullable":true},"unPackingComplete":{"type":"boolean","nullable":true},"unPackingFailed":{"type":"boolean","nullable":true},"uploadInProgress":{"type":"boolean","nullable":true},"url":{"type":"string","nullable":true},"hasChildren":{"type":"boolean","nullable":true},"resourceOwner":{"$ref":"#/components/schemas/Jylo.Toolkit.API.Models.OrganizationMemberModel"}},"additionalProperties":false},"Jylo.Toolkit.API.Models.OrganizationMemberModel":{"required":["id","name"],"type":"object","properties":{"email":{"type":"string","nullable":true},"name":{"type":"string","nullable":true},"id":{"type":"string","nullable":true}},"additionalProperties":false},"Microsoft.AspNetCore.Mvc.ProblemDetails":{"type":"object","properties":{"type":{"type":"string","nullable":true},"title":{"type":"string","nullable":true},"status":{"type":"integer","format":"int32","nullable":true},"detail":{"type":"string","nullable":true},"instance":{"type":"string","nullable":true}},"additionalProperties":{}}}},"paths":{"/playbooks/{playbookIdentifier}/source-documents/empty":{"post":{"tags":["Playbook Source Documents"],"summary":"Creates an empty playbook source document.","description":"Creates an empty playbook source document with specified file name and content type.","parameters":[{"name":"parentObjectIdentifier","in":"query","description":"The optional parent object identifier.","schema":{"type":"string","format":"uuid"}},{"name":"fileName","in":"query","description":"The name of the file.","required":true,"schema":{"type":"string"}},{"name":"contentType","in":"query","description":"The content type of the file.","required":true,"schema":{"type":"string"}},{"name":"documentUploadIdentifier","in":"query","description":"The unique identifier for the document upload.","required":true,"schema":{"type":"string","format":"uuid"}},{"name":"playbookIdentifier","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"Created","content":{"text/plain":{"schema":{"$ref":"#/components/schemas/Jylo.Toolkit.API.Models.Documents.DocumentReadModel"}},"application/json":{"schema":{"$ref":"#/components/schemas/Jylo.Toolkit.API.Models.Documents.DocumentReadModel"}},"text/json":{"schema":{"$ref":"#/components/schemas/Jylo.Toolkit.API.Models.Documents.DocumentReadModel"}}}},"400":{"description":"Bad Request","content":{"text/plain":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}},"application/json":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}},"text/json":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}}}},"403":{"description":"Forbidden","content":{"text/plain":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}},"application/json":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}},"text/json":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}}}}}}}}}
```

## Appends a chunk to a playbook source document upload.

> Uploads a file chunk to an existing playbook source document.

```json
{"openapi":"3.0.4","info":{"title":"Playbook Marketplace API","version":"v1"},"servers":[{"url":"https://api.{tenant}.{region}.jylo.ai","variables":{"tenant":{"default":"example","description":"Tenant name"},"region":{"default":"uk","description":"Region","enum":["uk","us","eu","au","jp"]}}}],"security":[{"Bearer":[]}],"components":{"securitySchemes":{"Bearer":{"type":"http","description":"Bearer authentication with JWT","scheme":"bearer","bearerFormat":"JWT"}},"schemas":{"Jylo.Toolkit.API.Models.Documents.DocumentReadModel":{"required":["documentUploadObjectIdentifier","name"],"type":"object","properties":{"name":{"type":"string","nullable":true},"parentObjectIdentifier":{"type":"string","format":"uuid","nullable":true},"isDirectory":{"type":"boolean"},"documentUploadObjectIdentifier":{"type":"string","format":"uuid"},"contentType":{"type":"string","nullable":true},"size":{"type":"integer","format":"int64","nullable":true},"objectIdentifier":{"type":"string","format":"uuid"},"dateAdded":{"type":"string","format":"date-time"},"uploadSuccessful":{"type":"boolean","nullable":true},"tokenCount":{"type":"integer","format":"int64","nullable":true},"metadataTokenCount":{"type":"integer","format":"int64","nullable":true},"unsupportedFileType":{"type":"boolean","nullable":true},"unPackingComplete":{"type":"boolean","nullable":true},"unPackingFailed":{"type":"boolean","nullable":true},"uploadInProgress":{"type":"boolean","nullable":true},"url":{"type":"string","nullable":true},"hasChildren":{"type":"boolean","nullable":true},"resourceOwner":{"$ref":"#/components/schemas/Jylo.Toolkit.API.Models.OrganizationMemberModel"}},"additionalProperties":false},"Jylo.Toolkit.API.Models.OrganizationMemberModel":{"required":["id","name"],"type":"object","properties":{"email":{"type":"string","nullable":true},"name":{"type":"string","nullable":true},"id":{"type":"string","nullable":true}},"additionalProperties":false},"Microsoft.AspNetCore.Mvc.ProblemDetails":{"type":"object","properties":{"type":{"type":"string","nullable":true},"title":{"type":"string","nullable":true},"status":{"type":"integer","format":"int32","nullable":true},"detail":{"type":"string","nullable":true},"instance":{"type":"string","nullable":true}},"additionalProperties":{}}}},"paths":{"/playbooks/{playbookIdentifier}/source-documents/{objectIdentifier}/append-chunk":{"post":{"tags":["Playbook Source Documents"],"summary":"Appends a chunk to a playbook source document upload.","description":"Uploads a file chunk to an existing playbook source document.","parameters":[{"name":"objectIdentifier","in":"path","description":"The unique identifier of the document.","required":true,"schema":{"type":"string","format":"uuid"}},{"name":"chunkIndex","in":"query","description":"The index of the chunk.","schema":{"type":"integer","format":"int32"}},{"name":"lastChunk","in":"query","description":"Indicates if this is the last chunk.","schema":{"type":"boolean","default":false}},{"name":"playbookIdentifier","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"content":{"multipart/form-data":{"schema":{"type":"object","properties":{"file":{"type":"string","description":"The file chunk to upload.","format":"binary"}}},"encoding":{"file":{"style":"form"}}}}},"responses":{"200":{"description":"OK","content":{"text/plain":{"schema":{"$ref":"#/components/schemas/Jylo.Toolkit.API.Models.Documents.DocumentReadModel"}},"application/json":{"schema":{"$ref":"#/components/schemas/Jylo.Toolkit.API.Models.Documents.DocumentReadModel"}},"text/json":{"schema":{"$ref":"#/components/schemas/Jylo.Toolkit.API.Models.Documents.DocumentReadModel"}}}},"400":{"description":"Bad Request","content":{"text/plain":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}},"application/json":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}},"text/json":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}}}},"403":{"description":"Forbidden","content":{"text/plain":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}},"application/json":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}},"text/json":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}}}},"404":{"description":"Not Found","content":{"text/plain":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}},"application/json":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}},"text/json":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}}}}}}}}}
```

## Gets a playbook source document by its object identifier.

> Retrieves a playbook source document by its unique identifier.

```json
{"openapi":"3.0.4","info":{"title":"Playbook Marketplace API","version":"v1"},"servers":[{"url":"https://api.{tenant}.{region}.jylo.ai","variables":{"tenant":{"default":"example","description":"Tenant name"},"region":{"default":"uk","description":"Region","enum":["uk","us","eu","au","jp"]}}}],"security":[{"Bearer":[]}],"components":{"securitySchemes":{"Bearer":{"type":"http","description":"Bearer authentication with JWT","scheme":"bearer","bearerFormat":"JWT"}},"schemas":{"Jylo.Toolkit.API.Models.Documents.DocumentReadModel":{"required":["documentUploadObjectIdentifier","name"],"type":"object","properties":{"name":{"type":"string","nullable":true},"parentObjectIdentifier":{"type":"string","format":"uuid","nullable":true},"isDirectory":{"type":"boolean"},"documentUploadObjectIdentifier":{"type":"string","format":"uuid"},"contentType":{"type":"string","nullable":true},"size":{"type":"integer","format":"int64","nullable":true},"objectIdentifier":{"type":"string","format":"uuid"},"dateAdded":{"type":"string","format":"date-time"},"uploadSuccessful":{"type":"boolean","nullable":true},"tokenCount":{"type":"integer","format":"int64","nullable":true},"metadataTokenCount":{"type":"integer","format":"int64","nullable":true},"unsupportedFileType":{"type":"boolean","nullable":true},"unPackingComplete":{"type":"boolean","nullable":true},"unPackingFailed":{"type":"boolean","nullable":true},"uploadInProgress":{"type":"boolean","nullable":true},"url":{"type":"string","nullable":true},"hasChildren":{"type":"boolean","nullable":true},"resourceOwner":{"$ref":"#/components/schemas/Jylo.Toolkit.API.Models.OrganizationMemberModel"}},"additionalProperties":false},"Jylo.Toolkit.API.Models.OrganizationMemberModel":{"required":["id","name"],"type":"object","properties":{"email":{"type":"string","nullable":true},"name":{"type":"string","nullable":true},"id":{"type":"string","nullable":true}},"additionalProperties":false},"Microsoft.AspNetCore.Mvc.ProblemDetails":{"type":"object","properties":{"type":{"type":"string","nullable":true},"title":{"type":"string","nullable":true},"status":{"type":"integer","format":"int32","nullable":true},"detail":{"type":"string","nullable":true},"instance":{"type":"string","nullable":true}},"additionalProperties":{}}}},"paths":{"/playbooks/{playbookIdentifier}/source-documents/{objectIdentifier}":{"get":{"tags":["Playbook Source Documents"],"summary":"Gets a playbook source document by its object identifier.","description":"Retrieves a playbook source document by its unique identifier.","parameters":[{"name":"objectIdentifier","in":"path","description":"The unique identifier of the document.","required":true,"schema":{"type":"string","format":"uuid"}},{"name":"playbookIdentifier","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"text/plain":{"schema":{"$ref":"#/components/schemas/Jylo.Toolkit.API.Models.Documents.DocumentReadModel"}},"application/json":{"schema":{"$ref":"#/components/schemas/Jylo.Toolkit.API.Models.Documents.DocumentReadModel"}},"text/json":{"schema":{"$ref":"#/components/schemas/Jylo.Toolkit.API.Models.Documents.DocumentReadModel"}}}},"403":{"description":"Forbidden","content":{"text/plain":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}},"application/json":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}},"text/json":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}}}},"404":{"description":"Not Found","content":{"text/plain":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}},"application/json":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}},"text/json":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}}}}}}}}}
```

## Updates a playbook source document by its object identifier.

> Updates a playbook source document by its unique identifier.

```json
{"openapi":"3.0.4","info":{"title":"Playbook Marketplace API","version":"v1"},"servers":[{"url":"https://api.{tenant}.{region}.jylo.ai","variables":{"tenant":{"default":"example","description":"Tenant name"},"region":{"default":"uk","description":"Region","enum":["uk","us","eu","au","jp"]}}}],"security":[{"Bearer":[]}],"components":{"securitySchemes":{"Bearer":{"type":"http","description":"Bearer authentication with JWT","scheme":"bearer","bearerFormat":"JWT"}},"schemas":{"Jylo.Toolkit.API.Models.Documents.DocumentWriteModel":{"required":["documentUploadObjectIdentifier","name"],"type":"object","properties":{"name":{"type":"string","nullable":true},"parentObjectIdentifier":{"type":"string","format":"uuid","nullable":true},"isDirectory":{"type":"boolean"},"documentUploadObjectIdentifier":{"type":"string","format":"uuid"}},"additionalProperties":false},"Jylo.Toolkit.API.Models.Documents.DocumentReadModel":{"required":["documentUploadObjectIdentifier","name"],"type":"object","properties":{"name":{"type":"string","nullable":true},"parentObjectIdentifier":{"type":"string","format":"uuid","nullable":true},"isDirectory":{"type":"boolean"},"documentUploadObjectIdentifier":{"type":"string","format":"uuid"},"contentType":{"type":"string","nullable":true},"size":{"type":"integer","format":"int64","nullable":true},"objectIdentifier":{"type":"string","format":"uuid"},"dateAdded":{"type":"string","format":"date-time"},"uploadSuccessful":{"type":"boolean","nullable":true},"tokenCount":{"type":"integer","format":"int64","nullable":true},"metadataTokenCount":{"type":"integer","format":"int64","nullable":true},"unsupportedFileType":{"type":"boolean","nullable":true},"unPackingComplete":{"type":"boolean","nullable":true},"unPackingFailed":{"type":"boolean","nullable":true},"uploadInProgress":{"type":"boolean","nullable":true},"url":{"type":"string","nullable":true},"hasChildren":{"type":"boolean","nullable":true},"resourceOwner":{"$ref":"#/components/schemas/Jylo.Toolkit.API.Models.OrganizationMemberModel"}},"additionalProperties":false},"Jylo.Toolkit.API.Models.OrganizationMemberModel":{"required":["id","name"],"type":"object","properties":{"email":{"type":"string","nullable":true},"name":{"type":"string","nullable":true},"id":{"type":"string","nullable":true}},"additionalProperties":false},"Microsoft.AspNetCore.Mvc.ProblemDetails":{"type":"object","properties":{"type":{"type":"string","nullable":true},"title":{"type":"string","nullable":true},"status":{"type":"integer","format":"int32","nullable":true},"detail":{"type":"string","nullable":true},"instance":{"type":"string","nullable":true}},"additionalProperties":{}}}},"paths":{"/playbooks/{playbookIdentifier}/source-documents/{objectIdentifier}":{"put":{"tags":["Playbook Source Documents"],"summary":"Updates a playbook source document by its object identifier.","description":"Updates a playbook source document by its unique identifier.","parameters":[{"name":"objectIdentifier","in":"path","description":"The unique identifier of the document to update.","required":true,"schema":{"type":"string","format":"uuid"}},{"name":"playbookIdentifier","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"description":"The updated document data.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Jylo.Toolkit.API.Models.Documents.DocumentWriteModel"}},"text/json":{"schema":{"$ref":"#/components/schemas/Jylo.Toolkit.API.Models.Documents.DocumentWriteModel"}},"application/*+json":{"schema":{"$ref":"#/components/schemas/Jylo.Toolkit.API.Models.Documents.DocumentWriteModel"}}}},"responses":{"200":{"description":"OK","content":{"text/plain":{"schema":{"$ref":"#/components/schemas/Jylo.Toolkit.API.Models.Documents.DocumentReadModel"}},"application/json":{"schema":{"$ref":"#/components/schemas/Jylo.Toolkit.API.Models.Documents.DocumentReadModel"}},"text/json":{"schema":{"$ref":"#/components/schemas/Jylo.Toolkit.API.Models.Documents.DocumentReadModel"}}}},"400":{"description":"Bad Request","content":{"text/plain":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}},"application/json":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}},"text/json":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}}}},"403":{"description":"Forbidden","content":{"text/plain":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}},"application/json":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}},"text/json":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}}}},"404":{"description":"Not Found","content":{"text/plain":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}},"application/json":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}},"text/json":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}}}}}}}}}
```

## Deletes a playbook source document by its object identifier.

> Deletes a playbook source document by its unique identifier.

```json
{"openapi":"3.0.4","info":{"title":"Playbook Marketplace API","version":"v1"},"servers":[{"url":"https://api.{tenant}.{region}.jylo.ai","variables":{"tenant":{"default":"example","description":"Tenant name"},"region":{"default":"uk","description":"Region","enum":["uk","us","eu","au","jp"]}}}],"security":[{"Bearer":[]}],"components":{"securitySchemes":{"Bearer":{"type":"http","description":"Bearer authentication with JWT","scheme":"bearer","bearerFormat":"JWT"}},"schemas":{"Microsoft.AspNetCore.Mvc.ProblemDetails":{"type":"object","properties":{"type":{"type":"string","nullable":true},"title":{"type":"string","nullable":true},"status":{"type":"integer","format":"int32","nullable":true},"detail":{"type":"string","nullable":true},"instance":{"type":"string","nullable":true}},"additionalProperties":{}}}},"paths":{"/playbooks/{playbookIdentifier}/source-documents/{objectIdentifier}":{"delete":{"tags":["Playbook Source Documents"],"summary":"Deletes a playbook source document by its object identifier.","description":"Deletes a playbook source document by its unique identifier.","parameters":[{"name":"objectIdentifier","in":"path","description":"The unique identifier of the document to delete.","required":true,"schema":{"type":"string","format":"uuid"}},{"name":"playbookIdentifier","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"No Content"},"403":{"description":"Forbidden","content":{"text/plain":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}},"application/json":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}},"text/json":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}}}},"404":{"description":"Not Found","content":{"text/plain":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}},"application/json":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}},"text/json":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}}}}}}}}}
```

## Adds a folder to the playbook source documents.

> Creates a new folder within the playbook source documents.

```json
{"openapi":"3.0.4","info":{"title":"Playbook Marketplace API","version":"v1"},"servers":[{"url":"https://api.{tenant}.{region}.jylo.ai","variables":{"tenant":{"default":"example","description":"Tenant name"},"region":{"default":"uk","description":"Region","enum":["uk","us","eu","au","jp"]}}}],"security":[{"Bearer":[]}],"components":{"securitySchemes":{"Bearer":{"type":"http","description":"Bearer authentication with JWT","scheme":"bearer","bearerFormat":"JWT"}},"schemas":{"Jylo.Toolkit.API.Models.FolderWriteModel":{"required":["name"],"type":"object","properties":{"name":{"type":"string","nullable":true},"parentObjectIdentifier":{"type":"string","format":"uuid","nullable":true}},"additionalProperties":false},"Jylo.Toolkit.API.Models.Documents.DocumentReadModel":{"required":["documentUploadObjectIdentifier","name"],"type":"object","properties":{"name":{"type":"string","nullable":true},"parentObjectIdentifier":{"type":"string","format":"uuid","nullable":true},"isDirectory":{"type":"boolean"},"documentUploadObjectIdentifier":{"type":"string","format":"uuid"},"contentType":{"type":"string","nullable":true},"size":{"type":"integer","format":"int64","nullable":true},"objectIdentifier":{"type":"string","format":"uuid"},"dateAdded":{"type":"string","format":"date-time"},"uploadSuccessful":{"type":"boolean","nullable":true},"tokenCount":{"type":"integer","format":"int64","nullable":true},"metadataTokenCount":{"type":"integer","format":"int64","nullable":true},"unsupportedFileType":{"type":"boolean","nullable":true},"unPackingComplete":{"type":"boolean","nullable":true},"unPackingFailed":{"type":"boolean","nullable":true},"uploadInProgress":{"type":"boolean","nullable":true},"url":{"type":"string","nullable":true},"hasChildren":{"type":"boolean","nullable":true},"resourceOwner":{"$ref":"#/components/schemas/Jylo.Toolkit.API.Models.OrganizationMemberModel"}},"additionalProperties":false},"Jylo.Toolkit.API.Models.OrganizationMemberModel":{"required":["id","name"],"type":"object","properties":{"email":{"type":"string","nullable":true},"name":{"type":"string","nullable":true},"id":{"type":"string","nullable":true}},"additionalProperties":false},"Microsoft.AspNetCore.Mvc.ProblemDetails":{"type":"object","properties":{"type":{"type":"string","nullable":true},"title":{"type":"string","nullable":true},"status":{"type":"integer","format":"int32","nullable":true},"detail":{"type":"string","nullable":true},"instance":{"type":"string","nullable":true}},"additionalProperties":{}}}},"paths":{"/playbooks/{playbookIdentifier}/source-documents/folder":{"post":{"tags":["Playbook Source Documents"],"summary":"Adds a folder to the playbook source documents.","description":"Creates a new folder within the playbook source documents.","parameters":[{"name":"playbookIdentifier","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"description":"The folder data to add.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Jylo.Toolkit.API.Models.FolderWriteModel"}},"text/json":{"schema":{"$ref":"#/components/schemas/Jylo.Toolkit.API.Models.FolderWriteModel"}},"application/*+json":{"schema":{"$ref":"#/components/schemas/Jylo.Toolkit.API.Models.FolderWriteModel"}}}},"responses":{"201":{"description":"Created","content":{"text/plain":{"schema":{"$ref":"#/components/schemas/Jylo.Toolkit.API.Models.Documents.DocumentReadModel"}},"application/json":{"schema":{"$ref":"#/components/schemas/Jylo.Toolkit.API.Models.Documents.DocumentReadModel"}},"text/json":{"schema":{"$ref":"#/components/schemas/Jylo.Toolkit.API.Models.Documents.DocumentReadModel"}}}},"400":{"description":"Bad Request","content":{"text/plain":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}},"application/json":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}},"text/json":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}}}},"403":{"description":"Forbidden","content":{"text/plain":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}},"application/json":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}},"text/json":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}}}}}}}}}
```

## Updates a folder by its object identifier.

> Updates a folder by its object identifier.

```json
{"openapi":"3.0.4","info":{"title":"Playbook Marketplace API","version":"v1"},"servers":[{"url":"https://api.{tenant}.{region}.jylo.ai","variables":{"tenant":{"default":"example","description":"Tenant name"},"region":{"default":"uk","description":"Region","enum":["uk","us","eu","au","jp"]}}}],"security":[{"Bearer":[]}],"components":{"securitySchemes":{"Bearer":{"type":"http","description":"Bearer authentication with JWT","scheme":"bearer","bearerFormat":"JWT"}},"schemas":{"Jylo.Toolkit.API.Models.FolderWriteModel":{"required":["name"],"type":"object","properties":{"name":{"type":"string","nullable":true},"parentObjectIdentifier":{"type":"string","format":"uuid","nullable":true}},"additionalProperties":false},"Jylo.Toolkit.API.Models.Documents.DocumentReadModel":{"required":["documentUploadObjectIdentifier","name"],"type":"object","properties":{"name":{"type":"string","nullable":true},"parentObjectIdentifier":{"type":"string","format":"uuid","nullable":true},"isDirectory":{"type":"boolean"},"documentUploadObjectIdentifier":{"type":"string","format":"uuid"},"contentType":{"type":"string","nullable":true},"size":{"type":"integer","format":"int64","nullable":true},"objectIdentifier":{"type":"string","format":"uuid"},"dateAdded":{"type":"string","format":"date-time"},"uploadSuccessful":{"type":"boolean","nullable":true},"tokenCount":{"type":"integer","format":"int64","nullable":true},"metadataTokenCount":{"type":"integer","format":"int64","nullable":true},"unsupportedFileType":{"type":"boolean","nullable":true},"unPackingComplete":{"type":"boolean","nullable":true},"unPackingFailed":{"type":"boolean","nullable":true},"uploadInProgress":{"type":"boolean","nullable":true},"url":{"type":"string","nullable":true},"hasChildren":{"type":"boolean","nullable":true},"resourceOwner":{"$ref":"#/components/schemas/Jylo.Toolkit.API.Models.OrganizationMemberModel"}},"additionalProperties":false},"Jylo.Toolkit.API.Models.OrganizationMemberModel":{"required":["id","name"],"type":"object","properties":{"email":{"type":"string","nullable":true},"name":{"type":"string","nullable":true},"id":{"type":"string","nullable":true}},"additionalProperties":false},"Microsoft.AspNetCore.Mvc.ProblemDetails":{"type":"object","properties":{"type":{"type":"string","nullable":true},"title":{"type":"string","nullable":true},"status":{"type":"integer","format":"int32","nullable":true},"detail":{"type":"string","nullable":true},"instance":{"type":"string","nullable":true}},"additionalProperties":{}}}},"paths":{"/playbooks/{playbookIdentifier}/source-documents/folder/{objectIdentifier}":{"put":{"tags":["Playbook Source Documents"],"summary":"Updates a folder by its object identifier.","description":"Updates a folder by its object identifier.","parameters":[{"name":"objectIdentifier","in":"path","description":"The unique identifier of the folder to update.","required":true,"schema":{"type":"string","format":"uuid"}},{"name":"playbookIdentifier","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"description":"The updated folder data.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Jylo.Toolkit.API.Models.FolderWriteModel"}},"text/json":{"schema":{"$ref":"#/components/schemas/Jylo.Toolkit.API.Models.FolderWriteModel"}},"application/*+json":{"schema":{"$ref":"#/components/schemas/Jylo.Toolkit.API.Models.FolderWriteModel"}}}},"responses":{"200":{"description":"OK","content":{"text/plain":{"schema":{"$ref":"#/components/schemas/Jylo.Toolkit.API.Models.Documents.DocumentReadModel"}},"application/json":{"schema":{"$ref":"#/components/schemas/Jylo.Toolkit.API.Models.Documents.DocumentReadModel"}},"text/json":{"schema":{"$ref":"#/components/schemas/Jylo.Toolkit.API.Models.Documents.DocumentReadModel"}}}},"400":{"description":"Bad Request","content":{"text/plain":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}},"application/json":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}},"text/json":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}}}},"403":{"description":"Forbidden","content":{"text/plain":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}},"application/json":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}},"text/json":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}}}},"404":{"description":"Not Found","content":{"text/plain":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}},"application/json":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}},"text/json":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}}}}}}}}}
```

## Downloads a playbook source document file by its object identifier.

> Downloads the file for a playbook source document by its unique identifier.

```json
{"openapi":"3.0.4","info":{"title":"Playbook Marketplace API","version":"v1"},"servers":[{"url":"https://api.{tenant}.{region}.jylo.ai","variables":{"tenant":{"default":"example","description":"Tenant name"},"region":{"default":"uk","description":"Region","enum":["uk","us","eu","au","jp"]}}}],"security":[{"Bearer":[]}],"components":{"securitySchemes":{"Bearer":{"type":"http","description":"Bearer authentication with JWT","scheme":"bearer","bearerFormat":"JWT"}},"schemas":{"Microsoft.AspNetCore.Mvc.ProblemDetails":{"type":"object","properties":{"type":{"type":"string","nullable":true},"title":{"type":"string","nullable":true},"status":{"type":"integer","format":"int32","nullable":true},"detail":{"type":"string","nullable":true},"instance":{"type":"string","nullable":true}},"additionalProperties":{}}}},"paths":{"/playbooks/{playbookIdentifier}/source-documents/{objectIdentifier}/download":{"get":{"tags":["Playbook Source Documents"],"summary":"Downloads a playbook source document file by its object identifier.","description":"Downloads the file for a playbook source document by its unique identifier.","parameters":[{"name":"objectIdentifier","in":"path","description":"The unique identifier of the document to download.","required":true,"schema":{"type":"string","format":"uuid"}},{"name":"playbookIdentifier","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"text/plain":{"schema":{"type":"string","format":"binary"}},"application/json":{"schema":{"type":"string","format":"binary"}},"text/json":{"schema":{"type":"string","format":"binary"}}}},"403":{"description":"Forbidden","content":{"text/plain":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}},"application/json":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}},"text/json":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}}}},"404":{"description":"Not Found","content":{"text/plain":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}},"application/json":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}},"text/json":{"schema":{"$ref":"#/components/schemas/Microsoft.AspNetCore.Mvc.ProblemDetails"}}}}}}}}}
```
