Model Management

List all Content Fragment Models

This operation provides support for retrieving all the Content Fragment Models accessible to the current user, determined via the applied request authorization. By default this call will return a maximum of 50 items.

The caller can define other limits suited to their application (see the limit query parameter), but the limit cannot be higher than 50. To ask for the next set of items pass the value of the cursor provided in the response to the cursor query parameter.

SecuritybearerAuth
Request
query Parameters
cursor
string (Cursor) non-empty

For a paginated request, this parameter defines the cursor from which to retrieve the next set of items.

limit
integer <int32> (Limit) [ 1 .. 50 ]

For a paginated request, this parameter defines the maximum number of items to retrieve.

enabledForFolder
string (ContentFragmentPath) ^\/content\/dam(\/.*)?$

The enabledForFolder query parameter allows the caller to filter the list of Content Fragment Models based on their availability for a certain DAM (Digital Assets Management) folder. As such, the provided path must be a DAM folder.

Responses
200

A list of Content Fragment Models was successfully returned.

400

Bad Request. The Problem Details object will provide more information about the exact cause.

403

Forbidden

406

Unacceptable. indicates that the target resource does not have a current representation that would be acceptable to the user agent, according to the proactive negotiation header fields received in the request.

get/cf/models
Request samples
Response samples
application/json
{
  • "items": [
    ],
  • "cursor": "string"
}

Create a Content Fragment Model

This operation allows creating one or more Content Fragment Models. The server will check the content-fragment field types and validate if the passed models are present in the request's payload or already available on the server.

SecuritybearerAuth
Request
Request Body schema: application/json

The request payload to create one or more Content Fragment Models.

Array of objects (CreateContentFragmentModel)
Responses
201

The Content Fragment Models were successfully created.

400

Bad Request. The Problem Details object will provide more information about the exact cause.

403

Forbidden

406

Unacceptable. indicates that the target resource does not have a current representation that would be acceptable to the user agent, according to the proactive negotiation header fields received in the request.

415

Unsupported Media Type. When provided as a response to a PATCH request, the response will provide an Accept-Patch response header to notify the client what patch document media types are supported.

500

The server encountered an unexpected error. Retrying the request after a certain time could help.

post/cf/models
Request samples
application/json
{
  • "models": [
    ]
}
Response samples
application/json
{
  • "items": [
    ]
}

Get a Content Fragment Model

SecuritybearerAuth
Request
path Parameters
id
required
string (Base64URLId)

The ID of the Content Fragment Model to retrieve.

header Parameters
If-None-Match
string

The If-None-Match header field makes the request method conditional on a recipient cache or origin server either not having any current representation of the target resource, when the field value is "*", or having a selected representation with an entity tag that does not match any of those listed in the field value.

For more details, please head over to RFC9110.

Responses
200

OK

304

Not Modified

400

Bad Request. The Problem Details object will provide more information about the exact cause.

403

Forbidden

404

Not Found

406

Unacceptable. indicates that the target resource does not have a current representation that would be acceptable to the user agent, according to the proactive negotiation header fields received in the request.

500

The server encountered an unexpected error. Retrying the request after a certain time could help.

get/cf/models/{id}
Request samples
Response samples
application/json
{
  • "id": "L2NvbmYvd2tuZC1zaGFyZWQvc2V0dGluZ3MvZGFtL2NmbS9tb2RlbHMvYWR2ZW50dXJl",
  • "path": "/conf/wknd-shared/settings/dam/cfm/models/adventure",
  • "name": "Adventure",
  • "etag": "eddd95e986a7aff0500f0649bcf6604c",
  • "description": "",
  • "created": {
    },
  • "modified": {
    },
  • "locked": false,
  • "status": "enabled",
  • "previewStatus": "IN_SYNC",
  • "fields": [
    ],
  • "tags": [
    ],
}

Get the details for a Content Fragment Model

This operation allows retrieving the headers for a Content Fragment Model, when a client needs to execute subsequent operations that need to be consistent (e.g. check an ETag value, check if the model still exists, etc.).

SecuritybearerAuth
Request
path Parameters
id
required
string (Base64URLId)

The ID of the Content Fragment Model to retrieve.

header Parameters
If-None-Match
string

The If-None-Match header field makes the request method conditional on a recipient cache or origin server either not having any current representation of the target resource, when the field value is "*", or having a selected representation with an entity tag that does not match any of those listed in the field value.

For more details, please head over to RFC9110.

Responses
200

OK

304

Not Modified

400

Bad Request

403

Forbidden

404

Not Found

500

Internal Server Error

head/cf/models/{id}
Request samples

Edit a Content Fragment Model

This operation allows editing a Content Fragment Model. The changes are passed as JSON Patch documents.

Save conflicts are detected by leveraging conditional HTTP requests. When a conflict occurs, the server will reply with a 412 response. It becomes the caller's responsibility to resolve the conflict, either by accepting the values from the server, or by overwriting them.

SecuritybearerAuth
Request
path Parameters
id
required
string (Base64URLId)

The ID of the Content Fragment Model to retrieve.

header Parameters
If-None-Match
string

The If-None-Match header field makes the request method conditional on a recipient cache or origin server either not having any current representation of the target resource, when the field value is "*", or having a selected representation with an entity tag that does not match any of those listed in the field value.

For more details, please head over to RFC9110.

If-Match
required
string

The If-Match header field makes the request method conditional on the recipient origin server either having at least one current representation of the target resource, when the field value is "*", or having a current representation of the target resource that has an entity tag matching a member of the list of entity tags provided in the field value.

For more details, please head over to RFC9110.

Request Body schema: application/json-patch+json
required
Array
One of:

Adds the contents of the value parameter to the location indicated by the path parameter.

path
required
string non-empty

The location where information should be added

op
required
string >= 3 characters

Identifies this operation as an add operation

Value: "add"
required
string or number or Array of any or object

The information to place at the location indicated by the path parameter

Responses
200

OK

400

Bad Request. The Problem Details object will provide more information about the exact cause.

403

Forbidden

404

Not Found

406

Unacceptable. indicates that the target resource does not have a current representation that would be acceptable to the user agent, according to the proactive negotiation header fields received in the request.

409

Conflict

412

Precondition Failed

415

Unsupported Media Type. When provided as a response to a PATCH request, the response will provide an Accept-Patch response header to notify the client what patch document media types are supported.

428

Precondition Required

500

The server encountered an unexpected error. Retrying the request after a certain time could help.

patch/cf/models/{id}
Request samples
application/json-patch+json
[
  • {
    }
]
Response samples
application/json
{
  • "id": "L2NvbmYvd2tuZC1zaGFyZWQvc2V0dGluZ3MvZGFtL2NmbS9tb2RlbHMvYWR2ZW50dXJl",
  • "path": "/conf/wknd-shared/settings/dam/cfm/models/adventure",
  • "name": "Name changed by PATCH CFM",
  • "description": "",
  • "created": {
    },
  • "modified": {
    },
  • "locked": false,
  • "status": "enabled",
  • "fields": [
    ],
  • "tags": [
    ]
}

Delete a Content Fragment Model

SecuritybearerAuth
Request
path Parameters
id
required
string (Base64URLId)

The ID of the Content Fragment Model to retrieve.

header Parameters
If-None-Match
string

The If-None-Match header field makes the request method conditional on a recipient cache or origin server either not having any current representation of the target resource, when the field value is "*", or having a selected representation with an entity tag that does not match any of those listed in the field value.

For more details, please head over to RFC9110.

If-Match
required
string

The If-Match header field makes the request method conditional on the recipient origin server either having at least one current representation of the target resource, when the field value is "*", or having a current representation of the target resource that has an entity tag matching a member of the list of entity tags provided in the field value.

For more details, please head over to RFC9110.

Responses
204

The delete operation completed successfully. The response body doesn't provide any content.

400

Bad Request. The Problem Details object will provide more information about the exact cause.

403

Forbidden

404

Not Found

409

Conflict

412

Precondition Failed

428

Precondition Required

500

The server encountered an unexpected error. Retrying the request after a certain time could help.

delete/cf/models/{id}
Request samples
Response samples
application/problem+json
{}

Publish Content Fragment Models

This operation starts an AEM workflow for publishing Content Fragment Models.

SecuritybearerAuth
Request
Request Body schema: application/json

Request parameters to publish content fragment models.

ids
required
Array of strings (Base64URLId) [ 1 .. 50 ] items unique

The list of content fragment model ids.

agentId
string
Default: "publish"

The agent id used for publishing the content fragment models.

filterAllowedModelIdsByStatus
required
Array of any unique

The status of the referenced models. A model is in draft as soon as it's created, unless the user specifically marks the model as enabled. A model is in disabled state only when a user explicitly disables the model.

Items Enum: "ENABLED" "DISABLED" "DRAFT"
workflowModelId
string
Default: "/etc/workflow/models/scheduled_model_activation_with_references"

The workflow model id used for initiating the workflow instance to handle the publication. AEM provides the designated model /etc/workflow/models/scheduled_model_activation_with_references for publishing contents including references.

workflowTitle
string

A freely defined non-empty string used to identify the workflow when it executes.

scheduledTime
integer <int64>

The scheduled time as an epoch timestamp.

Responses
200

OK

400

Bad Request. The Problem Details object will provide more information about the exact cause.

404

Not Found

406

Unacceptable. indicates that the target resource does not have a current representation that would be acceptable to the user agent, according to the proactive negotiation header fields received in the request.

415

Unsupported Media Type. When provided as a response to a PATCH request, the response will provide an Accept-Patch response header to notify the client what patch document media types are supported.

500

The server encountered an unexpected error. Retrying the request after a certain time could help.

post/cf/models/publish
Request samples
application/json
{
  • "ids": [
    ],
  • "filterAllowedModelIdsByStatus": [
    ],
  • "workflowModelId": "/etc/workflow/models/scheduled_model_activation_with_references",
  • "workflowTitle": "Workflow Title",
  • "scheduledTime": 1635244063701
}
Response samples
application/json
{
  • "workflowInstanceId": "/var/workflow/instances/server0/2022-01-21/scheduled_activation_with_references_23",
  • "items": [
    ]
}

Get the UI schema associated with the Content Fragment Model

SecuritybearerAuth
Request
path Parameters
id
required
string (Base64URLId)

The ID of the Content Fragment Model.

header Parameters
X-Adobe-Accept-Unsupported-API
required
integer

The X-Adobe-Accept-Unsupported-API request header is required when a client wants to opt-in into using a product-only API, not designed for public consumption. Not providing this header to an endpoint that requires it will make the server answer with a 400 status code.

Value: 1
Responses
200

A response containing a UI schema

404

Not Found

406

Unacceptable. indicates that the target resource does not have a current representation that would be acceptable to the user agent, according to the proactive negotiation header fields received in the request.

500

The server encountered an unexpected error. Retrying the request after a certain time could help.

get/cf/models/{id}/uiSchema
Request samples
Response samples
application/json
{
  • "uiSchema": {
    },
  • "modified": {
    }
}

Update the existing UI schema associated with a Content Fragment Model

SecuritybearerAuth
Request
path Parameters
id
required
string (Base64URLId)

The ID of the Content Fragment Model.

header Parameters
X-Adobe-Accept-Unsupported-API
required
integer

The X-Adobe-Accept-Unsupported-API request header is required when a client wants to opt-in into using a product-only API, not designed for public consumption. Not providing this header to an endpoint that requires it will make the server answer with a 400 status code.

Value: 1
If-Match
required
string

The If-Match header field makes the request method conditional on the recipient origin server either having at least one current representation of the target resource, when the field value is "*", or having a current representation of the target resource that has an entity tag matching a member of the list of entity tags provided in the field value.

For more details, please head over to RFC9110.

Request Body schema: application/json
required
type
required
string

Type of UI Schema element

object (Option)

Additional option for a UI Schema element.

object

Rules allow for dynamic aspects for a form, e.g. by hiding or disabling UI schema elements.

label
string non-empty

By default, controls use the name of property they point to as a label. You can customize this behaviour by specifying a label property.

scope
required
string (Scope) non-empty

The mandatory scope property expects a JSON reference value. It defines to which property of the data the control should be bound to. It can be bound to multiple properties by using the "#" value.

Responses
204

The UI schema was successfully updated.

400

Bad Request. The Problem Details object will provide more information about the exact cause.

403

Forbidden

404

Not Found

406

Unacceptable. indicates that the target resource does not have a current representation that would be acceptable to the user agent, according to the proactive negotiation header fields received in the request.

412

Precondition Failed

415

Unsupported Media Type. When provided as a response to a PATCH request, the response will provide an Accept-Patch response header to notify the client what patch document media types are supported.

428

Precondition Required

500

The server encountered an unexpected error. Retrying the request after a certain time could help.

put/cf/models/{id}/uiSchema
Request samples
application/json
{
  • "type": "Categorization",
  • "elements": [
    ]
}
Response samples
application/problem+json
{}