Project Artifacts

Project Artifacts are the data that gets sent to the printer when a Project is ordered. Artifacts are attached to a Project Version - if a Version is a "snapshot" of the project, the Artifacts are the parts that make up the picture. A Version might be made up of multiple Artifacts - for example, a 10x8 photobook might need 3 PDFs: The page content, The cover sticker and the spine label. Each of these PDFs would be an Artifact.

If a Project is edited after it has been ordered and a new copy is ordered, a new Version would be created and a new set of Artifacts describing the new state of the Project would be created. Once a Version has been ordered, the Artifacts belonging to that Version can no longer be altered.

When the contents of an Artifact are verified by MILK, the results of the inspection are stored as Artifact Events.

When providing Artifacts that are PDF files, the PDF Format Requirments must be met.

Requires:

Required Artifacts

Artifacts which are necessary for the print factory to produce a copy of the Project are known as Required Artifacts. These Required Artifacts will be created automatically when a new Version is created (and when a new Project is created) and set to Incomplete. These Artifacts will need to be completed before the Version is considered complete and available for ordering. Required Artifacts will be defined by MILK depending on the physical production requirements of the Product.

Other Artifacts

Other than Required Artifacts, additional Artifacts can be stored. For example, a thumbnail of the cover of a book could be stored as an Artifact, so that it could be displayed when viewing order history.

Deferred Artifacts

In some situations, Required Artifacts cannot be provided until after checkout has taken place - in this case the Artifacts must be marked as Deferred before the Version will be available for checkout.

Actions

URLVerbInformation
/project/{Project Guid}/version/{Version Number}/artifact/{Artifact Name}POSTCreates or updates an Artifact identified by the Artifact Name

Fields

The requests to the Artifact actions should be HTTP multipart file uploads containing one and only one file. Request should set the "Content-Type" HTTP header to "multipart/form-data" and a boundry as standard. Inside the part containing the file contents, the "Content-Type" must be included, specifying the type of the file being uploaded. If your upload technology does not allow you to set the "Content-Type" header of the part, this can be set at the request level by using the "X-Override-Content-Type" header. This header will override the one that is present in the part.

The following details are returned about an Artifact:

FieldData TypeRequiredInformation
NameStringYUniquely identifies the artifact in the Version
IsCompleteBooleanYIf the artifact is complete for the purposes of checkout, i.e. a file has been uploaded, or deferred.
FileMimeTypeStringYThe MIME type of the artifact. This is the only allowed content type on a Required Artifact
FileMd5StringNAn MD5 hash of the file contents. Only set if the artifact is complete and not deferred.
FileSizeLongNLength of the file in bytes. Only set if the artifact is complete and not deferred.
DeferredProjectArtifactDeferredNDefer settings for the artifact. Only set if the artifact is deferred.