ReleaseItem

View as Markdown

ReleaseItem

ReleaseItem for create or update release items.

Create

The Create request allows you to add an item (entry or asset) to a Release. To add entries/assets to a Release, you need to provide the UIDs of the entries/assets in ‘items’ in the request body.

NameTypeDescription
model (required)ReleaseItemModel

ReleaseItem Model for creating ReleaseItem.

collectionParameterCollection

Query parameter collection

using Contentstack.Management.Core;

using Contentstack.Management.Core.Models;


ContentstackClient client = new ContentstackClient("<AUTHTOKEN>");

ReleaseItemModel model = new ReleaseItemModel();

ContentstackResponse contentstackResponse = client.Stack("<API_KEY>").Release("<RELEASE_UID>").Item().Create(model);

CreateAsync

The Create request allows you to add an item (entry or asset) to a Release. To add entries/assets to a Release, you need to provide the UIDs of the entries/assets in ‘items’ in the request body.

NameTypeDescription
model (required)ReleaseItemModel

ReleaseItem Model for creating ReleaseItem.

collectionParameterCollection

Query parameter collection

using Contentstack.Management.Core;

using Contentstack.Management.Core.Models;


ContentstackClient client = new ContentstackClient("<AUTHTOKEN>");

ReleaseItemModel model = new ReleaseItemModel();

ContentstackResponse contentstackResponse = await client.Stack("<API_KEY>").Release("<RELEASE_UID>").Item().CreateAsync(model);

CreateMultiple

The Create request allows you to add multiple items (entries and/or assets) to a Release. To add entries/assets to a Release, you need to provide the UIDs of the entries/assets in ‘items’ in the request body.

NameTypeDescription
models (required)List<ReleaseItemModel>

List of ReleaseItem Model for creating ReleaseItem.

collectionParameterCollection

Query parameter collection

using Contentstack.Management.Core;

using Contentstack.Management.Core.Models;


ContentstackClient client = new ContentstackClient("<AUTHTOKEN>");

ReleaseItemModel model = new ReleaseItemModel();

List<ReleaseItemModel> models = new List<ReleaseItemModel>()

{

    model,

};

ContentstackResponse contentstackResponse = client.Stack("<API_KEY>").Release("<RELEASE_UID>").Item().CreateMultiple(models);

CreateMultipleAsync

The Create request allows you to add multiple items (entries and/or assets) to a Release. To add entries/assets to a Release, you need to provide the UIDs of the entries/assets in ‘items’ in the request body.

NameTypeDescription
models (required)List<ReleaseItemModel>

List of ReleaseItem Model for creating ReleaseItem.

collectionParameterCollection

Query parameter collection

using Contentstack.Management.Core;

using Contentstack.Management.Core.Models;


ContentstackClient client = new ContentstackClient("<AUTHTOKEN>");

ReleaseItemModel model = new ReleaseItemModel();

List<ReleaseItemModel> models = new List<ReleaseItemModel>()

{

    model,

};

ContentstackResponse contentstackResponse = await client.Stack("<API_KEY>").Release("<RELEASE_UID>").Item().CreateMultipleAsync(models);

Delete

The Delete request deletes one or more items (entries and/or assets) from a specific Release.

NameTypeDescription
models (required)List<ReleaseItemModel>

List of ReleaseItemModel to be deleted.

collectionParameterCollection

Query parameter collection

using Contentstack.Management.Core;

using Contentstack.Management.Core.Models;


ContentstackClient client = new ContentstackClient("<AUTHTOKEN>");

ReleaseItemModel model = new ReleaseItemModel();

List<ReleaseItemModel> models = new List<ReleaseItemModel>()

{

    model,

};

ContentstackResponse contentstackResponse = client.Stack("<API_KEY>").Release("<RELEASE_UID>").Item("<RELEASE_ITEM_UID>").Delete(models);

DeleteAsync

The Delete request deletes one or more items (entries and/or assets) from a specific Release.

NameTypeDescription
models (required)List<ReleaseItemModel>

List of ReleaseItemModel to be deleted.

collectionParameterCollection

Query parameter collection

using Contentstack.Management.Core;

using Contentstack.Management.Core.Models;


ContentstackClient client = new ContentstackClient("<AUTHTOKEN>");

ReleaseItemModel model = new ReleaseItemModel();

List<ReleaseItemModel> models = new List<ReleaseItemModel>()

{

    model,

};

ContentstackResponse contentstackResponse = await client.Stack("<API_KEY>").Release("<RELEASE_UID>").Item("<RELEASE_ITEM_UID>").DeleteAsync(models);

GetAll

The Get all request retrieves a list of all items (entries and assets) that are part of a specific Release.

NameTypeDescription
collectionParameterCollection

Query parameter collection

using Contentstack.Management.Core;

using Contentstack.Management.Core.Models;


ContentstackClient client = new ContentstackClient("<AUTHTOKEN>");

ContentstackResponse contentstackResponse = client.Stack("<API_KEY>").Release("<RELEASE_UID>").Item().GetAll();

GetAllAsync

The Get all request retrieves a list of all items (entries and assets) that are part of a specific Release.

NameTypeDescription
collectionParameterCollection

Query parameter collection

using Contentstack.Management.Core;

using Contentstack.Management.Core.Models;


ContentstackClient client = new ContentstackClient("<AUTHTOKEN>");

ContentstackResponse contentstackResponse = await client.Stack("<API_KEY>").Release("<RELEASE_UID>").Item().GetAllAsync();

UpdateReleaseItem

The Update Release items to their latest versions request let you update all the release items (entries and assets) to their latest versions before deployment.

NameTypeDescription
items (required)List<String>

Release items to update or "$all" for updating all release items.

using Contentstack.Management.Core;

using Contentstack.Management.Core.Models;


ContentstackClient client = new ContentstackClient("<AUTHTOKEN>");

List<string> items = new List<string>(){

  "<$all>"

}

ContentstackResponse contentstackResponse = client.Stack("<API_KEY>").Release("<RELEASE_UID>").Item().UpdateReleaseItem(model);

UpdateReleaseItemAsync

The Update Release items to their latest versions request let you update all the release items (entries and assets) to their latest versions before deployment.

NameTypeDescription
items (required)List<String>

Release items to update or "$all" for updating all release items.

using Contentstack.Management.Core;

using Contentstack.Management.Core.Models;


ContentstackClient client = new ContentstackClient("<AUTHTOKEN>");

List<string> items = new List<string>(){

  "<$all>"

}

ContentstackResponse contentstackResponse = await client.Stack("<API_KEY>").Release("<RELEASE_UID>").Item().UpdateReleaseItemAsync(items);