One asset
const url = 'https://app.currentpim.se/api/v1/assets/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://app.currentpim.se/api/v1/assets/example \ --header 'Authorization: Bearer <token>'Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”The asset code.
Responses
Section titled “Responses”The asset and its file.
object
object
Alt text per locale code.
object
Title per locale code.
object
Caption per locale code.
object
The workspace’s asset metadata fields (Settings → Metadata fields) in the product value structure: field code → “” → locale code or “” → value.
object
object
The point cover renditions crop around, in 0–1 from the top left; null is the centre.
object
What the picture said about itself when it arrived (EXIF, IPTC, XMP): camera, lens, exposure, aperture, iso, focal_length, software, orientation, gps, title, caption, keywords, byline, credit, copyright, source, taken_at. Renditions carry none of it.
object
When the picture was taken, from its metadata.
Usage rights: feeds leave out files that are expired or not yet usable.
object
Draft, approved or archived: only approved files leave the PIM.
Whether the file may leave the PIM today: approved, and usable by its usage rights. Feeds, shops and share links leave out the others; product values keep naming them.
Asset category codes.
The code of the supplier the file came from, when known.
SHA-256 of the file.
Every name the file arrived under.
object
media:<id>, what product values and writes use.
Bytes.
Pixels across a picture as it is shown: one its camera turned a quarter (EXIF orientation 5 to 8) is measured turned. Null for other files and for pictures whose size can’t be read.
Pixels down, likewise.
How a picture lies, from its width and height.
Serves the file without a session for as long as it exists.
A 240 px JPEG, images only.
A 1200 px JPEG, images only.
Lasting URLs of the file in every rendition of the workspace (Settings → Renditions), by rendition code: files/{tenant}/{media}/{rendition}/{version}.{ext}, immutable and cacheable for a year; the version changes with the file, its focal point and the rendition’s settings. Empty for files that can’t have renditions (documents without a preview).
object
Example
{ "data": { "kind": "image", "rights": { "state": "ok" }, "status": "draft", "source": "library", "file": { "orientation": "landscape" } }}No valid token (missing, revoked, expired, or the account is deactivated).
object
Problems by field, e.g. values.price._._ or items.0.identifier (422 only).
object
Example generated
{ "message": "example", "errors": { "additionalProperty": [ "example" ] }}The token lacks the ability or the account the permission.
object
Problems by field, e.g. values.price._._ or items.0.identifier (422 only).
object
Example generated
{ "message": "example", "errors": { "additionalProperty": [ "example" ] }}No asset with this code.
object
Problems by field, e.g. values.price._._ or items.0.identifier (422 only).
object
Example generated
{ "message": "example", "errors": { "additionalProperty": [ "example" ] }}More than the allowed requests a minute for this token; Retry-After says when to try again.
object
Problems by field, e.g. values.price._._ or items.0.identifier (422 only).
object
Example generated
{ "message": "example", "errors": { "additionalProperty": [ "example" ] }}