Create a revision of a treatment definition group

post/definitionGroups/{groupId}/revisions

Creates a new revision of a treatment definition group based on the representation in the request body.

Request Samples

1

Response Samples

1{
2 "name": "My Treatment Definition Group",
3 "checkout": false,
4 "locked": false,
5 "sourceRevisionUri": "/treatmentDefinitions/definitionGroups/6b53e248-1afb-4147-b17a-13e75b8c759b/revisions/0340f630-3ee6-4058-ad36-744619c141d5",
6 "copyTimeStamp": "2020-06-17T13:37:01.750Z",
7 "members": [
8 {
9 "definitionId": "60095dcd-b2ca-4705-8cf6-aa693fce1692"
10 },
11 {
12 "definitionId": "60095dcd-b2ca-4705-8cf6-aa693fce1692",
13 "definitionRevisionId": "f813702e-dff8-443e-a7af-727ab027fb7e",
14 "attributeValueMappings": [
15 {
16 "attributeId": "fdb1e22e-5358-4311-a914-eec901c2da5f",
17 "mappingType": "variable",
18 "value": "Discount"
19 },
20 {
21 "attributeId": "7c17cbaf-dd3d-4288-b6a9-54ae7c7c91c6",
22 "mappingType": "constant",
23 "value": "Samsung"
24 },
25 {
26 "attributeId": "a0a3b4d4-fc28-4194-84dd-fe2dc3286009",
27 "mappingType": "variable",
28 "value": "Clicked"
29 }
30 ],
31 "attributeNameAliases": [
32 {
33 "attributeId": "fdb1e22e-5358-4311-a914-eec901c2da5f",
34 "aliasName": "Discount ID"
35 }
36 ]
37 }
38 ]
39}

Path Parameters

NameTypeRequiredDescription
groupId
string
true

The unique identifier for the treatment definition group.

Query Parameters

NameTypeRequiredDescription
fromRevisionUri
string
false

This value specifies the URI of the treatment definition group revision this new treatment definition group revision is being created from. This property allows for the lineage of a treatment definition group to be traced. The valid format for this parameter is '/treatmentDefinitions/definitionGroups/${groupId}/revisions/${revisionId}'

revisionType
string
false

Valid values are major or minor. This value determines how the server generates the major and minor numbers. If a major number is provided, the next available major version number is started. For example, if the treatment definition group has revisions 1.0, 1.1, 1.2, 2.0, and 2.1, creating a new major revision results in 3.0. If a minor number is provided, then the next available minor revision number is reserved based on the existing revisions. For example, if the existing revisions have major and minor numbers of 1.1, 1.2, 1.3, 2.1, 2.2, and a user requests a new minor revision, then 2.3 is assigned. This parameter defaults to minor if not supplied.

Allowed values:
majorminor

Request Body

Treatment definition group details that must be created as a revision.

The representation of a treatment definition group.

NameTypeRequiredDescription
id
string
false

The system-assigned unique ID for this object

name
string
true

The treatment definition group name.

description
string
false

The treatment definition group description.

createdBy
string
false

The user who created the treatment definition group.

creationTimeStamp
string<date-time>
false

The date and time that the treatment definition group was created.

modifiedBy
string
false

The userId of the authenticated user who last updated the treatment definition group.

modifiedTimeStamp
string<date-time>
false

The date and time that the treatment definition group was last modified.

majorRevision
integer
false

Major version number of the revision being viewed of the treatment definition group. This value is assigned by the service, the user only has control on whether the major number or minor number is incremented when creating a new revision. This is a derived field which is generated on POST.

minorRevision
integer
false

Minor version number of the current revision of the treatment definition group. This value is assigned by the service, the user only has control on whether the major number or minor number is incremented when creating a new revision. This is a derived field which is generated on POST.

checkout
boolean
false

Flag which indicates that this treatment group is a user's working copy of another treatment group.

locked
boolean
false

Flag which indicates if the content of the revision being viewed is locked or editable.

activationStatus
string<enumeration>
false

Status of the activation.

Allowed values:
activeinactivependingrunningcancelledtimedOutfailed
activationError
Error
false

The representation of an error.

activatedTimeStamp
string<date-time>
false

The date and time that the treatment definition group revision was activated.

status
string<enumeration>
false

Status of the treatment definition.

Allowed values:
validerror
members
array [Treatment Definition Group Member]
false

The group of treatment definition members.

folderType
string
false

Indicates the kind of folder where the treatment definition group is housed.

sourceRevisionUri
string
false

The URI of the treatment definition group revision this treatment definition group is being created from.

copyTimeStamp
string<date-time>
false

The time stamp when the treatment definition group revision was copied.

links
array [Link]
false

Zero or more links to related resources or operations.

version
integer
false

This media type's schema version number. This representation is version 4.

Responses

StatusMeaningDescription
201Created

A revision of a treatment definition group was created.

HeadersSchema
400Bad Request

The request was invalid.

HeadersSchema