Authentication & Security
Q: What is the recommended method for authenticating with the API? A: It is strongly recommended to use the OAuth 2.0 protocol with JWT (JSON Web Tokens) rather than basic authentication. The JWT token must be generated and signed using a shared private key with the HMAC algorithm (minimum SHA256).
Q: What does a 401 Unauthorized error mean? A: A 401 error indicates that the provided authorization is incomplete, invalid, or expired. This often happens when a JWT token is no longer valid or if the client secret has expired, requiring a renewal of the credentials to restore the connection.
Media Import & Management
Q: How do I upload a new media file via the API? A: Uploading is a multi-step process: first, upload the physical file via a
POST request to /api/dam/files, which will return a temporary file descriptor. Then, use that file descriptor link to create the media object in the target folder via a POST request to /api/dam/folders/{folderId}/medias.Q: How should I handle large file uploads? A: For large files, it is highly recommended to upload the file by chunks using the
PUT method on the file resource,. This ensures stability and allows resumable uploads by specifying the Content-Length and Content-Range headers for each chunk.Bulk Operations & Exports
Q: How can I update multiple media assets at once? A: You should use the mass update (bulk) feature by creating a selection, populating it with media IDs (up to 10,000), and executing the bulk operation,,. Note that the actual bulk update operation is limited to 300 media assets per call, so larger selections must be processed in batches.
Q: Are there limits on media exports? A: Yes, standard exports are generally limited to 200 items. For direct exports without asynchronous background processing, the limit is strictly 10 items; exceeding this threshold results in an error 500 in the API, and the system automatically falls back to sending an email with the download link instead of an immediate API response.
Search & Performance
Q: How can I improve the response time of my API search requests? A: The golden rule for the search API is that the less data it has to send, the faster it will be. You should use the
size parameter for pagination (default is 20) and the fields parameter to select only the necessary information (e.g., fields=id,title,_links{kpk:medium}) instead of loading the entire JSON structure.
Comments
0 comments
Please sign in to leave a comment.