{ "opencollection": "1.0.0", "info": { "name": "Drupal JSON: Comments Files API", "version": "1.1" }, "request": { "auth": { "type": "basic", "username": "{{username}}", "password": "{{password}}" } }, "items": [ { "info": { "name": "Files", "type": "folder" }, "items": [ { "info": { "name": "List file entities", "type": "http" }, "http": { "method": "GET", "url": "https://example.com/jsonapi/file/file", "headers": [ { "name": "Accept", "value": "" } ], "params": [ { "name": "filter[name][path]", "value": "", "type": "query", "description": "The dotted field path to filter on, e.g. title, status, uid.name, or field_tags.name for nested relationship fields." }, { "name": "filter[name][value]", "value": "", "type": "query", "description": "The value to filter against." }, { "name": "sort", "value": "", "type": "query", "description": "Sort the results by the given field. Prefix with - for descending order. For example, sort=title for ascending by title or sort=-created for descending by creation date." }, { "name": "page[limit]", "value": "", "type": "query", "description": "The maximum number of resources to return in a single page. Used for cursor-based pagination." }, { "name": "page[offset]", "value": "", "type": "query", "description": "The number of resources to skip before beginning to return results. Used in combination with page[limit] for pagination." }, { "name": "fields[node--article]", "value": "", "type": "query", "description": "Sparse fieldset parameter to limit which attributes are returned, reducing response payload size. Replace node--article with the relevant resource type. Value is a comma-separated list of field names." } ] }, "docs": "Retrieves a collection of file entities. Returns file metadata including filename, MIME type, size, and URI. Requires authentication with appropriate file access permissions." }, { "info": { "name": "Get a file entity", "type": "http" }, "http": { "method": "GET", "url": "https://example.com/jsonapi/file/file/:uuid", "headers": [ { "name": "Accept", "value": "" } ], "params": [ { "name": "uuid", "value": "", "type": "path", "description": "The UUID of the entity. JSON:API always uses UUID as the identifier, not the numeric entity ID." }, { "name": "fields[node--article]", "value": "", "type": "query", "description": "Sparse fieldset parameter to limit which attributes are returned, reducing response payload size. Replace node--article with the relevant resource type. Value is a comma-separated list of field names." } ] }, "docs": "Retrieves a single file entity by UUID. Returns file metadata. The file binary is accessible via the URI field returned in the response." }, { "info": { "name": "Delete a file entity", "type": "http" }, "http": { "method": "DELETE", "url": "https://example.com/jsonapi/file/file/:uuid", "params": [ { "name": "uuid", "value": "", "type": "path", "description": "The UUID of the entity. JSON:API always uses UUID as the identifier, not the numeric entity ID." } ] }, "docs": "Permanently deletes a file entity and its associated file from storage by UUID. Requires file management permissions and authentication." }, { "info": { "name": "Get a file entity", "type": "http" }, "http": { "method": "GET", "url": "https://example.com/jsonapi/file/:id", "headers": [ { "name": "Accept", "value": "" } ], "params": [ { "name": "id", "value": "", "type": "path", "description": "The numeric ID of the entity." } ] }, "docs": "Retrieves a single file entity by its numeric ID. Returns metadata about the file including filename, MIME type, size, URI, and upload timestamps. Does not return the raw file binary; use the file URI to download the file." }, { "info": { "name": "Delete a file entity", "type": "http" }, "http": { "method": "DELETE", "url": "https://example.com/jsonapi/file/:id", "params": [ { "name": "id", "value": "", "type": "path", "description": "The numeric ID of the entity." } ] }, "docs": "Permanently deletes a file entity and its associated file from the Drupal file system by its numeric ID. Requires file management permissions and authentication." } ] } ], "bundled": true }