Get a file’s details
GET
/media/{id}
const url = 'https://postflow.biz.id/api/v1/media/example';const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url https://postflow.biz.id/api/v1/media/example \ --header 'Authorization: Bearer <token>'Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”id
required
string
Media id
Responses
Section titled “Responses”OK
Media typeapplication/json
object
id
required
Use in mediaIds.
string
kind
required
string
mime
required
string
sizeBytes
required
integer
originalName
required
string
url
required
App path of the file. With the API, download it from /media/{id}/file.
string
createdAt
required
string format: date-time
Example
{ "kind": "image", "mime": "image/jpeg"}Missing, invalid, expired or deleted key or token.
Media typeapplication/json
object
error
required
object
code
required
string
message
required
A sentence you can show to a person.
string
details
Field errors ({ field: [messages] }), or preflight: per-account rule violations with an issue code.
Example
{ "error": { "code": "UNAUTHENTICATED" }}Not found in this workspace.
Media typeapplication/json
object
error
required
object
code
required
string
message
required
A sentence you can show to a person.
string
details
Field errors ({ field: [messages] }), or preflight: per-account rule violations with an issue code.
Example
{ "error": { "code": "UNAUTHENTICATED" }}More than 120 requests in a minute with this key.
Media typeapplication/json
object
error
required
object
code
required
string
message
required
A sentence you can show to a person.
string
details
Field errors ({ field: [messages] }), or preflight: per-account rule violations with an issue code.
Example
{ "error": { "code": "UNAUTHENTICATED" }}