Get a File
GEThttps://https://euwest.api.elasticpath.com/v2/files/:fileID
Get a File
Request
Path Parameters
fileID stringrequired
The unique identifier for a file.
Responses
- 200
- 404
- 500
- application/json
- Schema
- Example (from schema)
- default
Schema
data File
{
"data": {
"id": "00000000-0000-0000-0000-000000000000",
"type": "file",
"file_name": "file_name.jpg",
"mime_type": "image/jpeg",
"file_size": 36000,
"public": true,
"meta": {
"timestamps": {
"created_at": "2023-10-11T13:02:25.293Z"
},
"dimensions": {
"width": 1800,
"height": 1000
}
},
"links": {
"self": "https://https://euwest.api.elasticpath.com//v2/files/ddc28c74-a7df-46be-b262-8fa69a6e7d52"
},
"link": {
"href": "https://files-eu.epusercontent.com/e8c53cb0-120d-4ea5-8941-ce74dec06038/f8cf26b3-6d38-4275-937a-624a83994702.png"
}
}
}
{
"data": {
"type": "file",
"id": "f8cf26b3-6d38-4275-937a-624a83994702",
"link": {
"href": "https://files-eu.epusercontent.com/e8c53cb0-120d-4ea5-8941-ce74dec06038/f8cf26b3-6d38-4275-937a-624a83994702.png"
},
"file_name": "f6669358-85db-4367-9cde-1deb77acb5f4.png",
"mime_type": "image/png",
"file_size": 110041,
"meta": {
"dimensions": {
"width": 1000,
"height": 1000
},
"timestamps": {
"created_at": "2018-03-13T13:45:21.673Z"
}
},
"links": {
"self": "https://useast.api.elasticpath.com/v2/files/f8cf26b3-6d38-4275-937a-624a83994702"
}
}
}
Forbidden. The operation is forbidden on this entity.
- application/json
- Schema
- Example (from schema)
Schema
errors Error[]required
{
"errors": [
{
"status": 500,
"title": "Internal server error",
"detail": "An internal error has occurred.",
"request_id": "00000000-0000-0000-0000-000000000000",
"meta": {
"missing_ids": [
"e7d50bd5-1833-43c0-9848-f9d325b08be8"
]
}
}
]
}
Internal server error. There was a system failure in the platform.
- application/json
- Schema
- Example (from schema)
- internal-server-error
Schema
errors Error[]required
{
"errors": [
{
"status": 500,
"title": "Internal server error",
"detail": "An internal error has occurred.",
"request_id": "00000000-0000-0000-0000-000000000000",
"meta": {
"missing_ids": [
"e7d50bd5-1833-43c0-9848-f9d325b08be8"
]
}
}
]
}
{
"errors": [
{
"status": 500,
"title": "Internal Server Error",
"detail": "There was an internal server error, you can report with your request id.",
"request_id": "635da56d-75a1-43cd-b696-7ab119756b3a"
}
]
}
Authorization: http
name: bearerAuthtype: httpscheme: bearer
- curl
- python
- go
- nodejs
- ruby
- csharp
- php
- java
- powershell
- CURL
curl -L -X GET 'https://https://euwest.api.elasticpath.com/v2/files/:fileID' \
-H 'Accept: application/json' \
-H 'Authorization: Bearer <TOKEN>'
ResponseClear