Create a Repository

post

/content/management/api/v1.1/repositories

Creates a repository with the given payload.

Request

Supported Media Types
Query Parameters
Header Parameters
Body ()
Creates a repository with the given information in the payload. The fields id, createdBy, createdDate, updatedBy, updatedDate and links will be ignored even if given in the payload.
Root Schema : Repository
Type: object
Repository
Show Source
Nested Schema : channels
Type: array
Channels associated with the repository.
Show Source
Nested Schema : configuredLanguages
Type: array
Configured Languages of the repository.
Show Source
Nested Schema : connectors
Type: array
Connectors associated with the repository.
Show Source
Nested Schema : contentTypes
Type: array
Types associated with the repository.
Show Source
Nested Schema : date
Type: object
date
Show Source
Nested Schema : editorialRoles
Type: array
Editorial roles associated with the repository.
Show Source
Nested Schema : languageOptions
Type: array
Language options for the repository.
Show Source
Nested Schema : taxonomies
Type: array
Taxonomies associated with the repository.
Show Source
Nested Schema : TypeWorkflowsBean
Type: object
TypeWorkflowsBean
Show Source
Nested Schema : workflows
Type: array
Workflows associated with the repository.
Show Source
Nested Schema : ChannelBeanInRepository
Type: object
ChannelBeanInRepository
Show Source
Nested Schema : optionalLanguages
Type: array
Optional Languages.
Show Source
Nested Schema : requiredLanguages
Type: array
Required Languages.
Show Source
Nested Schema : Connector
Type: object
Connector
Show Source
Nested Schema : supportedContentTypes
Type: array
Supported content types of the connector.
Show Source
Nested Schema : ContentTypeId
Type: object
Show Source
Nested Schema : EditorialRoleId
Type: object
EditorialRoleId
Show Source
Nested Schema : TaxonomyId
Type: object
TaxonomyId
Show Source
Nested Schema : WorkflowsOnAllAssetTypes
Type: object
Workflows on all asset types.
Show Source
Nested Schema : types
Type: array
Specific asset types.
Show Source
Nested Schema : default
Type: array
Manual start.
Show Source
Nested Schema : startOnCreate
Type: array
Automatic start on create.
Show Source
Nested Schema : WorkflowBean
Type: object
WorkflowBean
Show Source
Nested Schema : WorkflowsOnSpecificAssetTypes
Type: object
Workflows on specific asset types.
Show Source
Nested Schema : default
Type: array
Manual start.
Show Source
Nested Schema : startOnCreate
Type: array
Automatic start on create.
Show Source
Nested Schema : WorkflowId
Type: object
WorkflowId
Show Source
Back to Top

Response

Supported Media Types

201 Response

Created.
Body ()
Root Schema : Repository
Type: object
Repository
Show Source
Nested Schema : channels
Type: array
Channels associated with the repository.
Show Source
Nested Schema : configuredLanguages
Type: array
Configured Languages of the repository.
Show Source
Nested Schema : connectors
Type: array
Connectors associated with the repository.
Show Source
Nested Schema : contentTypes
Type: array
Types associated with the repository.
Show Source
Nested Schema : date
Type: object
date
Show Source
Nested Schema : editorialRoles
Type: array
Editorial roles associated with the repository.
Show Source
Nested Schema : languageOptions
Type: array
Language options for the repository.
Show Source
Nested Schema : taxonomies
Type: array
Taxonomies associated with the repository.
Show Source
Nested Schema : TypeWorkflowsBean
Type: object
TypeWorkflowsBean
Show Source
Nested Schema : workflows
Type: array
Workflows associated with the repository.
Show Source
Nested Schema : ChannelBeanInRepository
Type: object
ChannelBeanInRepository
Show Source
Nested Schema : optionalLanguages
Type: array
Optional Languages.
Show Source
Nested Schema : requiredLanguages
Type: array
Required Languages.
Show Source
Nested Schema : Connector
Type: object
Connector
Show Source
Nested Schema : supportedContentTypes
Type: array
Supported content types of the connector.
Show Source
Nested Schema : ContentTypeId
Type: object
Show Source
Nested Schema : EditorialRoleId
Type: object
EditorialRoleId
Show Source
Nested Schema : TaxonomyId
Type: object
TaxonomyId
Show Source
Nested Schema : WorkflowsOnAllAssetTypes
Type: object
Workflows on all asset types.
Show Source
Nested Schema : types
Type: array
Specific asset types.
Show Source
Nested Schema : default
Type: array
Manual start.
Show Source
Nested Schema : startOnCreate
Type: array
Automatic start on create.
Show Source
Nested Schema : WorkflowBean
Type: object
WorkflowBean
Show Source
Nested Schema : WorkflowsOnSpecificAssetTypes
Type: object
Workflows on specific asset types.
Show Source
Nested Schema : default
Type: array
Manual start.
Show Source
Nested Schema : startOnCreate
Type: array
Automatic start on create.
Show Source
Nested Schema : WorkflowId
Type: object
WorkflowId
Show Source

400 Response

Bad request.

403 Response

Forbidden.

404 Response

Not found.

500 Response

Internal server error.
Back to Top

Examples

The following example shows how to create a repository by submitting a POST request on the REST resource using cURL.

curl -X POST -H 'Content-Type: application/json' -H 'X-Requested-With: XMLHttpRequest' 'https://host:port/content/management/api/v1.1/repositories'

Example 1:

This creates a simple repository with name, description and default language, where en-IN is language code. Replace payload with your own data.

/content/management/api/v1.1/repositories

Request Payload

{
     "name": "repository1",
     "description": "repository1 description.",
     "defaultLanguage": "en-IN"
}      

Example 2:

This creates a simple Business repository with name, description, default language and list of optional languages associated with it, where en-US, en and de are language codes. Replace payload with your own data..

/content/management/api/v1.1/repositories

Request Payload

{
        "name": "repository1",
        "description": "repository1 description.",
        "repositoryType": "Business",
        "defaultLanguage": "en-US",
        "languageOptions": [
          "en",
          "de"
        ]
   }      

Example 3:

This creates a Standard repository with default language and list of optional languages associated with it, where en-US, en and de are language codes. Replace payload with your own data.

/content/management/api/v1.1/repositories

Request Payload

{
        "name": "repository2",
        "description": "repository2 description.",
        "defaultLanguage": "en-US",
        "repositoryType": "Standard",
        "languageOptions": [
          "en",
          "de"
        ]
 }       

Example 4:

This creates a repository with default language and a list of types associated with it. Where en-US is language code and Type1, Type2 are names of already existing types. Replace payload with your own data.

/content/management/api/v1.1/repositories

Request Payload

{
        "name": "repository3",
        "description": "repository3 description.",
        "contentTypes": [
          {
            "name": "Type1"
          },
          {
            "name": "Type2"
          }
        ],
        "defaultLanguage": "en-US"
 }      

Example 5:

This creates a repository with default language and list of channels associated with it. Where en-US is language code and CC1E1B4619A093A53A5378F8777746FB9E2ACCDF37A6, CCA47722BC777B16DC5FB1452A24C5FB6D9A33EF76A2 are id's of existing channels. Replace payload with your own data.

/content/management/api/v1.1/repositories

Request Payload

{
        "name": "repository4",
        "description": "repository4 description.",
        "channels": [
          {
            "id": "CC1E1B4619A093A53A5378F8777746FB9E2ACCDF37A6"
          },
          {
            "id": "CCA47722BC777B16DC5FB1452A24C5FB6D9A33EF76A2"
          }
        ],
        "defaultLanguage": "en-US"
 }      

Example 6:

This creates a Business repository with list of types associated with it. Where Type1, Type2 are names of existing types. Replace payload with your own data.

/content/management/api/v1.1/repositories

Request Payload

{
        "name": "repository5",
        "description": "repository5 description.",
        "contentTypes": [
          {
            "name": "Type1",
            "typeCategory": "ContentType"
          },
          {
            "name": "Type2",
            "typeCategory": "ContentType"
          },
          {
            "name": "myImage",
            "typeCategory": "DigitalAssetType"
          },
          {
            "name": "Image",
            "typeCategory": "DigitalAssetType"
          }
        ],
        "defaultLanguage": "en-US",
        "repositoryType": "Business"
 }      

Example 7:

This creates a repository with defaultlanguage, list of optional languages, list of types and list of channels associated with it. Where en-US, en, de are language codes, CC1E1B4619A093A53A5378F8777746FB9E2ACCDF37A6, CCA47722BC777B16DC5FB1452A24C5FB6D9A33EF76A2 are id's of already existing channels and Type1, Type2 are names of existing types. Replace payload with your own data.

/content/management/api/v1.1/repositories

Request Payload

{
        "name": "repository5",
        "description": "repository5 description.",
        "contentTypes": [
          {
            "name": "Type1",
            "typeCategory": "ContentType"
          },
          {
            "name": "Type2",
            "typeCategory": "ContentType"
          },
          {
            "name": "myImage",
            "typeCategory": "DigitalAssetType"
          },
          {
            "name": "Image",
            "typeCategory": "DigitalAssetType"
          }
        ],
        "channels": [
          {
            "id": "CC1E1B4619A093A53A5378F8777746FB9E2ACCDF37A6"
          },
          {
            "id": "CCA47722BC777B16DC5FB1452A24C5FB6D9A33EF76A2"
          }
        ],
        "defaultLanguage": "en-US",
        "languageOptions": [
          "en",
          "de"
        ]
   }      

Example 8:

This creates a repository with list of types, list of workflows associated. Where Type1, Type2 are names of existing types and D7D268693C094189A6377E805482C991, B8D268693C094189A6377E805482C673 are existing workflow id's. Replace payload with your own data.

/content/management/api/v1.1/repositories

Request Payload

{
        "name": "repository5",
        "description": "repository5 description.",
        "contentTypes": [
          {
            "name": "Type1"
          },
          {
            "name": "Type2"
          }
        ],
        "workflows": [
          {
            "id": "D7D268693C094189A6377E805482C991"
          },
          {
            "id": "E8D268693C094189A6377E805482C954"
          }
        ]
  }      

Example 9:

This creates a repository with list of types, list of workflows and associates workflows to the asset types. Replace payload with your own data.

/content/management/api/v1.1/repositories

Request Payload

{
        "name": "repository5",
        "description": "repository5 description.",
        "contentTypes": [
          {
            "name": "Type1"
          },
          {
            "name": "Type2"
          }
        ],
        "workflows": [
          {
            "id": "D7D268693C094189A6377E805482C991"
          },
          {
            "id": "E8D268693C094189A6377E805482C954"
          },
          {
            "id": "D217A8693C094189A6377E8056ER2346"
          }
        ],
        "typeWorkflows": {
          "allTypes": {
            "startOnCreate": [
              {
                "id": "D7D268693C094189A6377E805482C991"
              }
            ],
            "default": [
              {
                "id": "E8D268693C094189A6377E805482C954"
              }
            ],
            "required": false
          },
          "types": [
            {
              "id": "9B8395177F204AF79A6E2A0DD37CF616",
              "name": "type1",
              "startOnCreate": [
                {
                  "id": "E8D268693C094189A6377E805482C954"
                }
              ],
              "default": [
                {
                  "id": "D7D268693C094189A6377E805482C991"
                }
              ],
              "required": true
            },
            {
              "id": "D7E395177F204AF79A6E2A0DD3723F5E",
              "name": "type2",
              "startOnCreate": [
                {
                  "id": "D217A8693C094189A6377E8056ER2346"
                }
              ],
              "default": [
                {
                  "id": "E8D268693C094189A6377E805482C954"
                }
              ],
              "required": false
            }
          ]
        }
      }      

Example 10:

This creates a repository with default language and a list of connectors associated with it. where 1000 and 1002 are id's of already enabled connectors. Replace payload with your own data.

/content/management/api/v1.1/repositories

Request Payload

{
        "name": "repository6",
        "description": "repository6 description.",
        "contentTypes": [
        ],
        "channels": [
        ],
        "defaultLanguage": "en-US",
        "connectors": [
          {
            "connectorId": "10000"
          },
          {
            "connectorId": "10002"
          }
        ]
      }      

Example 11:

This creates a simple repository with name, description, default language and supporting advanced video as Video-Plus is assigned in types, where en-US is language code. Replace payload with your own data.

/content/management/api/v1.1/repositories

Request Payload

{
        "name": "Video repository",
        "description": "repository supports advanced video.",
        "defaultLanguage": "en-US",
        "contentTypes": [
          {
            "name": "Video-Plus"
          }
        ]
      }      

Example 12:

Creating a Business repository with name, description, default language and Video-Plus assigned in types will fail since Advanced videos not supported in Business repository.

/content/management/api/v1.1/repositories

Request Payload

{
        "name": "Video repository",
        "description": "Business repository supporting advanced video.",
        "defaultLanguage": "en-US",
        "contentTypes": [
          {
            "name": "Video-Plus"
          }
        ]
      }      

Example 13:

Creating a Business repository with list of channels associated with it will fail since channels are not supported in Business repository.

/content/management/api/v1.1/repositories

Request Payload

{
        "name": "repository2",
        "description": "repository2 description.",
        "defaultLanguage": "en-US",
        "repositoryType": "Business",
        "channels": [
          {
            "id": "CC1E1B4619A093A53A5378F8777746FB9E2ACCDF37A6"
          },
          {
            "id": "CCA47722BC777B16DC5FB1452A24C5FB6D9A33EF76A2"
          }
        ]
      }  

Example 14:

This creates a repository with list of types and list of custom editorial roles associated. Replace payload with your own data.

/content/management/api/v1.1/repositories

Request Payload

{
        "name": "repository7",
        "description": "repository7 description.",
		"repositoryType": "Standard",
        "contentTypes": [
          {
            "name": "Type1"
          },
          {
            "name": "Type2"
          }
        ],
        "editorialRoles": [
          {
            "id": "2C8E850048FB4DB4AAE317FA74751454"
          },
          {
            "id": "7EFD29110FE041ADAC888CCFAEE2923B"
          }
        ],
        "defaultLanguage": "en-US"
      }  

Example 15:

This creates a standard repository with name, description and default language settings, auto tagging (aka smart content) is enabled, and view all collections is disabled. Replace payload with your own data.

/content/management/api/v1.1/repositories

Request Payload

{
  "name": "repository1",
  "description": "repository1 description.",
  "repositoryType": "Standard",
  "defaultLanguage": "en-US",
  "autoTagEnabled": true,
  "viewAllCollectionsEnabled": false
} 

Request Headers

{
  "Content-Type": "application/json",
  "X-Requested-With": "XMLHttpRequest"
}

Response Code

201
Back to Top